// Token: 0x0600012B RID: 299 RVA: 0x000057D0 File Offset: 0x000039D0
        protected ConfigObject ConstructConfigObject(Type objectType, DataSourceInfo dsi, PropertyBag propertyBag, bool fIsNew)
        {
            ConfigObjectDelegate configObjectDelegate = null;
            ConstructorInfo      constructorInfo      = null;

            this.StampStorageIdentity(propertyBag);
            object obj = DataSourceManager.constructorHashtable[objectType];

            if (obj == null)
            {
                DataSourceManager.CacheObjectCreationInfo(objectType, ref configObjectDelegate, ref constructorInfo);
            }
            else
            {
                configObjectDelegate = (obj as ConfigObjectDelegate);
                constructorInfo      = (obj as ConstructorInfo);
            }
            ConfigObject configObject;

            if (configObjectDelegate != null)
            {
                configObject = configObjectDelegate(propertyBag);
            }
            else
            {
                configObject = (ConfigObject)constructorInfo.Invoke(null);
                configObject.SetIsNew(fIsNew);
                configObject.Fields = propertyBag;
            }
            configObject.SetDataSourceInfo(dsi);
            configObject.InitializeDefaults();
            configObject.Fields.ResetChangeTracking();
            return(configObject);
        }
 // Token: 0x06000147 RID: 327 RVA: 0x00005B78 File Offset: 0x00003D78
 public DataSourceSession(DataSourceInfo dataSourceInfo)
 {
     ExTraceGlobals.DataSourceSessionTracer.Information((long)this.GetHashCode(), "DataSourceSession::DataSourceSession - initializing data source session with data source info type {0}.", new object[]
     {
         (dataSourceInfo == null) ? "null" : dataSourceInfo.GetType()
     });
     this.dataSourceInfo = dataSourceInfo;
 }
예제 #3
0
 public DataSourceInfo(DataSourceInfo template)
 {
     ExTraceGlobals.DataSourceInfoTracer.Information((long)this.GetHashCode(), "DataSourceInfo::DataSourceInfo - initializing data source info from template.");
     if (template != null)
     {
         this.managementServer = template.ManagementServer;
         this.connectionString = template.ConnectionString;
         this.userName         = template.UserName;
     }
 }
예제 #4
0
 public void SetDataSourceInfo(DataSourceInfo dsi)
 {
     this.dataSourceInfo = dsi;
 }