feat : 토큰 인증 RestApi 구현 / Token기반 haskKey구현 / Dummy, User Token체크 분기
This commit is contained in:
12
MMOTestServer/MMOserver/Utils/Singleton.cs
Normal file
12
MMOTestServer/MMOserver/Utils/Singleton.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
namespace MMOserver.Utils;
|
||||
|
||||
public abstract class Singleton<T> where T : Singleton<T>, new()
|
||||
{
|
||||
private static readonly Lazy<T> instance = new Lazy<T>(static () => new T(), LazyThreadSafetyMode.ExecutionAndPublication);
|
||||
|
||||
public static T Instance => instance.Value;
|
||||
|
||||
protected Singleton()
|
||||
{
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user