You can design any C# Class as a Singleton Class. By doing so you can not use it any other way.
Or you can design your Classes as Standard Classes and subclass them with this Class into a Singleton:
internal static class Singleton<t> where T : new()
{
private static ConcurrentDictionary<type, t=""> _instances =
new ConcurrentDictionary<type, t="">();</type,></type,></t>
public static T Instance
{
get
{
return _instances.GetOrAdd(typeof(T), (t) => new T());
}
}
}
Then simply turn a normal Class into a Singleton via:
Singleton<MyClass>.Instance.MyMethodCall();