mirror of
https://github.com/ppy/osu.git
synced 2024-11-12 07:27:51 +08:00
22 lines
580 B
C#
22 lines
580 B
C#
|
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
|||
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
|||
|
|
|||
|
namespace osu.Game.Database
|
|||
|
{
|
|||
|
public class SingletonContextFactory : DatabaseContextFactory
|
|||
|
{
|
|||
|
private readonly OsuDbContext context;
|
|||
|
|
|||
|
public SingletonContextFactory(OsuDbContext context)
|
|||
|
: base(null)
|
|||
|
{
|
|||
|
this.context = context;
|
|||
|
}
|
|||
|
|
|||
|
protected override OsuDbContext CreateContext()
|
|||
|
{
|
|||
|
return context;
|
|||
|
}
|
|||
|
}
|
|||
|
}
|