public class Test
{
#region 单例
///<summary>
///单例对象
///</summary>
private static Singleton<Test> Singleton;
///<summary>
///实例
///</summary>
public static Test Instance
{
get
{
if (Singleton == null)
{
Singleton = new Singleton<Test>();
}
return Singleton.Instance;
}
}
}
时间: 2024-10-12 10:52:19