protected virtual ISettings GetDefaultSection(string name, IConfigurationSource source) { if (source.HasSection(name) == false) { source.AddStorage(new RuntimeStorage(name)); } return(source.GetSection(name)); }
protected void Initialize(IConfigurationSource source) { foreach (var storage in Storages) { if (storage.StorageType == StorageType.File) { source.AddFile(storage.FilePath); } else if (storage.StorageType == StorageType.Runtime) { source.AddStorage(storage.Storage); } } }