From ae90ac282a4c16eaf1dc451fb130aa9d6bf14f64 Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 10 May 2021 18:00:02 +0800 Subject: -remove --- Singleton/Singleton.cs | 28 ---------------------------- 1 file changed, 28 deletions(-) delete mode 100644 Singleton/Singleton.cs (limited to 'Singleton') diff --git a/Singleton/Singleton.cs b/Singleton/Singleton.cs deleted file mode 100644 index 4b5ae47..0000000 --- a/Singleton/Singleton.cs +++ /dev/null @@ -1,28 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; - -namespace Assets.Scripts.Tools.Singleton -{ - class Singleton where T : class, new() - { - private static T _instance; - - public static T Instance - { - get - { - if (_instance == null) - _instance = new T(); - return _instance; - } - } - - public static void Release() - { - if (_instance != null) - _instance = null; - } - } -} -- cgit v1.1-26-g67d0