Пример #1
0
        object IInternalConfigSystem.GetSection(string sectionName)
        {
            PrepareClientConfigSystem(sectionName);

            // Get the appropriate config record for the section.
            IInternalConfigRecord configRecord = null;

            if (DoesSectionOnlyUseMachineConfig(sectionName))
            {
                if (_isMachineConfigInited)
                {
                    configRecord = _machineConfigRecord;
                }
            }
            else
            {
                if (_isUserConfigInited)
                {
                    configRecord = _completeConfigRecord;
                }
            }

            // Call GetSection(), or return null if no configuration is yet available.
            return(configRecord?.GetSection(sectionName));
        }
        object IInternalConfigSystem.GetSection(string sectionName)
        {
            this.PrepareClientConfigSystem(sectionName);
            IInternalConfigRecord record = null;

            if (this.DoesSectionOnlyUseMachineConfig(sectionName))
            {
                if (this._isMachineConfigInited)
                {
                    record = this._machineConfigRecord;
                }
            }
            else if (this._isUserConfigInited)
            {
                record = this._completeConfigRecord;
            }
            if (record != null)
            {
                return(record.GetSection(sectionName));
            }
            return(null);
        }
Пример #3
0
 protected override object GetAppWebSection(string sectionName)
 {
     return(configRecord.GetSection(sectionName));
 }
Пример #4
0
        public object GetSection(string section, string configPath)
        {
            IInternalConfigRecord rec = GetConfigRecord(configPath);

            return(rec.GetSection(section));
        }
Пример #5
0
 protected virtual object GetSectionObject(string sectionName)
 {
     return(_configRecord.GetSection(sectionName));
 }