Пример #1
0
        protected Base()
        {
            type = GetType();

            factory = SyncFactory.GetOrCreateSyncFactory(type);

            propertyChangedDict = new Dictionary <string, DlgtPropertyChanged>();
        }
Пример #2
0
        public static SyncFactory GetOrCreateSyncFactory(Type InType)
        {
            SyncFactory factory = null;

            if (!factoriesDict.TryGetValue(InType, out factory))
            {
                try
                {
                    factory = new SyncFactory(InType);
                    factoriesDict.Add(InType, factory);
                }
                catch (Exception ex)
                {
                    Debug.LogError(InType + " Create SyncFactory Error : " + ex.Message);
                }
            }

            return(factory);
        }