mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-07-30 16:58:38 +00:00
Refactor Database class (#616)
Refactor Database into DatabaseContext Moved into separate folder so it actually has a namespace instead sitting in the root
This commit is contained in:
parent
2aff26f83d
commit
64b95e807d
246 changed files with 1211 additions and 965 deletions
|
@ -1,5 +1,6 @@
|
|||
#nullable enable
|
||||
using LBPUnion.ProjectLighthouse.Configuration;
|
||||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Logging;
|
||||
using LBPUnion.ProjectLighthouse.Serialization;
|
||||
|
@ -21,9 +22,9 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/xml")]
|
||||
public class CollectionController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
private readonly DatabaseContext database;
|
||||
|
||||
public CollectionController(Database database)
|
||||
public CollectionController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Helpers;
|
||||
using LBPUnion.ProjectLighthouse.Types.Entities.Interaction;
|
||||
|
@ -17,9 +18,9 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/plain")]
|
||||
public class LevelTagsController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
private readonly DatabaseContext database;
|
||||
|
||||
public LevelTagsController(Database database)
|
||||
public LevelTagsController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#nullable enable
|
||||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Helpers;
|
||||
using LBPUnion.ProjectLighthouse.Serialization;
|
||||
|
@ -20,8 +21,8 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/xml")]
|
||||
public class ListController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
public ListController(Database database)
|
||||
private readonly DatabaseContext database;
|
||||
public ListController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#nullable enable
|
||||
using LBPUnion.ProjectLighthouse.Configuration;
|
||||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Files;
|
||||
using LBPUnion.ProjectLighthouse.Helpers;
|
||||
|
@ -24,9 +25,9 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/xml")]
|
||||
public class PublishController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
private readonly DatabaseContext database;
|
||||
|
||||
public PublishController(Database database)
|
||||
public PublishController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#nullable enable
|
||||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Helpers;
|
||||
using LBPUnion.ProjectLighthouse.Serialization;
|
||||
|
@ -18,9 +19,9 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/xml")]
|
||||
public class ReviewController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
private readonly DatabaseContext database;
|
||||
|
||||
public ReviewController(Database database)
|
||||
public ReviewController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#nullable enable
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Helpers;
|
||||
using LBPUnion.ProjectLighthouse.Logging;
|
||||
|
@ -22,9 +23,9 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/xml")]
|
||||
public class ScoreController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
private readonly DatabaseContext database;
|
||||
|
||||
public ScoreController(Database database)
|
||||
public ScoreController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#nullable enable
|
||||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Serialization;
|
||||
using LBPUnion.ProjectLighthouse.Types.Entities.Level;
|
||||
|
@ -16,8 +17,8 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/xml")]
|
||||
public class SearchController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
public SearchController(Database database)
|
||||
private readonly DatabaseContext database;
|
||||
public SearchController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#nullable enable
|
||||
using LBPUnion.ProjectLighthouse.Configuration;
|
||||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Extensions;
|
||||
using LBPUnion.ProjectLighthouse.Helpers;
|
||||
using LBPUnion.ProjectLighthouse.Serialization;
|
||||
|
@ -21,8 +22,8 @@ namespace LBPUnion.ProjectLighthouse.Servers.GameServer.Controllers.Slots;
|
|||
[Produces("text/xml")]
|
||||
public class SlotsController : ControllerBase
|
||||
{
|
||||
private readonly Database database;
|
||||
public SlotsController(Database database)
|
||||
private readonly DatabaseContext database;
|
||||
public SlotsController(DatabaseContext database)
|
||||
{
|
||||
this.database = database;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue