mirror of
https://github.com/wismna/ModernKeePass.git
synced 2025-10-04 08:00:16 -04:00
13 lines
285 B
C#
13 lines
285 B
C#
![]() |
using System;
|
|||
|
|
|||
|
namespace ModernKeePass.Services
|
|||
|
{
|
|||
|
public abstract class SingletonServiceBase<T> where T : new()
|
|||
|
{
|
|||
|
private static readonly Lazy<T> LazyInstance =
|
|||
|
new Lazy<T>(() => new T());
|
|||
|
|
|||
|
public static T Instance => LazyInstance.Value;
|
|||
|
}
|
|||
|
}
|