Zhonghui

每个不曾起舞的日子,都是对生命的辜负

User Tools

Site Tools


程序:csharp:单例

C#单例


#region Signleton
protected static AD_WwiseManager _instance = new AD_WwiseManager();
 
private bool m_bInitialized = false;
 
public static AD_WwiseManager Instance
{
    get
    {
        _instance.Init();
        return _instance;
    }
}
 
private void Init()
{
    if (m_bInitialized) return;
 
    m_bInitialized = true;
}
#endregion
/var/www/DokuWikiStick/dokuwiki/data/pages/程序/csharp/单例.txt · Last modified: 2022/12/14 06:59 by zh