Untitled

mail@pastecode.io avatar
unknown
plain_text
a month ago
307 B
3
Indexable
Never
    public static class ServiceLocator<T> where T : class
    {
        private static T _value;

        public static T Get()
        {
            return _value;
        }

        public static T Set(T value)
        {
            _value = value;
            return _value;
        }
    }
Leave a Comment