示例#1
0
 static MemberManager()
 {
     Configuration.Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
     if (config.AppSettings.Settings.AllKeys.Contains("MemberManagerProvider"))
     {
         try
         {
             Type type = System.Reflection.TypeDelegator.GetType(config.AppSettings.Settings["MemberManagerProvider"].Value);
             if (type != null)
             {
                 provider = (MemberManagerProvider)Activator.CreateInstance(type);
                 return;
             }
         }
         catch
         {
         }
     }
     provider = new DefaultMemberManager();
 }
示例#2
0
        static MemberManager()
        {
            Configuration.Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
            if (config.AppSettings.Settings.AllKeys.Contains("MemberManagerProvider"))
            {
                try
                {
                    Type type = System.Reflection.TypeDelegator.GetType(config.AppSettings.Settings["MemberManagerProvider"].Value);
                    if (type!=null)
                    {
                        provider = (MemberManagerProvider)Activator.CreateInstance(type);
                        return;
                    }
                }
                catch
                {

                }                
            }
            provider = new DefaultMemberManager();
        }