Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / Configuration / System / Configuration / ProviderSettingsCollection.cs / 1 / ProviderSettingsCollection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.IO; using System.Text; using System.Globalization; [ConfigurationCollection(typeof(ProviderSettings))] public sealed class ProviderSettingsCollection : ConfigurationElementCollection { static private ConfigurationPropertyCollection _properties; static ProviderSettingsCollection() { // Property initialization _properties = new ConfigurationPropertyCollection(); } public ProviderSettingsCollection() : base(StringComparer.OrdinalIgnoreCase) { } protected internal override ConfigurationPropertyCollection Properties { get { return _properties; } } public void Add(ProviderSettings provider) { if (provider != null) { provider.UpdatePropertyCollection(); BaseAdd(provider); } } public void Remove(String name) { BaseRemove(name); } public void Clear() { BaseClear(); } protected override ConfigurationElement CreateNewElement() { return new ProviderSettings(); } protected override Object GetElementKey(ConfigurationElement element) { return ((ProviderSettings)element).Name; } public new ProviderSettings this[string key] { get { return (ProviderSettings)BaseGet(key); } } public ProviderSettings this[int index] { get { return (ProviderSettings)BaseGet(index); } set { if (BaseGet(index) != null) BaseRemoveAt(index); BaseAdd(index,value); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.IO; using System.Text; using System.Globalization; [ConfigurationCollection(typeof(ProviderSettings))] public sealed class ProviderSettingsCollection : ConfigurationElementCollection { static private ConfigurationPropertyCollection _properties; static ProviderSettingsCollection() { // Property initialization _properties = new ConfigurationPropertyCollection(); } public ProviderSettingsCollection() : base(StringComparer.OrdinalIgnoreCase) { } protected internal override ConfigurationPropertyCollection Properties { get { return _properties; } } public void Add(ProviderSettings provider) { if (provider != null) { provider.UpdatePropertyCollection(); BaseAdd(provider); } } public void Remove(String name) { BaseRemove(name); } public void Clear() { BaseClear(); } protected override ConfigurationElement CreateNewElement() { return new ProviderSettings(); } protected override Object GetElementKey(ConfigurationElement element) { return ((ProviderSettings)element).Name; } public new ProviderSettings this[string key] { get { return (ProviderSettings)BaseGet(key); } } public ProviderSettings this[int index] { get { return (ProviderSettings)BaseGet(index); } set { if (BaseGet(index) != null) BaseRemoveAt(index); BaseAdd(index,value); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DebugTrace.cs
- ControlOperationInvoker.cs
- HtmlSelect.cs
- InvalidComObjectException.cs
- ComponentChangingEvent.cs
- XmlDataSource.cs
- PropertyGridEditorPart.cs
- BindingNavigator.cs
- TdsEnums.cs
- Win32Native.cs
- CodeMemberField.cs
- Nodes.cs
- RootBrowserWindowProxy.cs
- TimelineGroup.cs
- EventLogPermissionEntry.cs
- ImageSourceConverter.cs
- ScrollItemProviderWrapper.cs
- SetterBase.cs
- EntitySqlQueryBuilder.cs
- HScrollProperties.cs
- InnerItemCollectionView.cs
- HttpHandlersSection.cs
- TagPrefixAttribute.cs
- WebConvert.cs
- MD5.cs
- AttributeData.cs
- OracleParameterBinding.cs
- RandomNumberGenerator.cs
- PersonalizationStateInfo.cs
- UserValidatedEventArgs.cs
- GeneralTransform3D.cs
- OleDbEnumerator.cs
- DataSourceListEditor.cs
- HttpException.cs
- XmlSchemaValidator.cs
- InstanceCreationEditor.cs
- MethodBuilderInstantiation.cs
- MapPathBasedVirtualPathProvider.cs
- RestClientProxyHandler.cs
- TraceHwndHost.cs
- RenamedEventArgs.cs
- ContentElementAutomationPeer.cs
- TimeSpanConverter.cs
- TreeNodeEventArgs.cs
- ColorConvertedBitmapExtension.cs
- HtmlTableRowCollection.cs
- ParallelTimeline.cs
- SpecularMaterial.cs
- SvcMapFileSerializer.cs
- SafeNativeMethods.cs
- SystemDropShadowChrome.cs
- SpotLight.cs
- KnownAssemblyEntry.cs
- FixedPageStructure.cs
- ConfigurationPropertyAttribute.cs
- _BaseOverlappedAsyncResult.cs
- CounterCreationDataCollection.cs
- BackEase.cs
- DataControlFieldCell.cs
- GradientBrush.cs
- CodeDelegateInvokeExpression.cs
- AsymmetricKeyExchangeDeformatter.cs
- ObjectItemCollection.cs
- CodeTypeDeclarationCollection.cs
- Size.cs
- CodeIdentifier.cs
- BamlReader.cs
- DefaultWorkflowSchedulerService.cs
- NumericUpDown.cs
- TransportManager.cs
- __FastResourceComparer.cs
- SecurityPermission.cs
- XMLUtil.cs
- ListViewDataItem.cs
- _Rfc2616CacheValidators.cs
- OpenCollectionAsyncResult.cs
- ConfigXmlSignificantWhitespace.cs
- GridViewDeletedEventArgs.cs
- AppDomain.cs
- ListBoxDesigner.cs
- DivideByZeroException.cs
- XmlBaseReader.cs
- FrameworkElement.cs
- CompressStream.cs
- ClientOperationFormatterProvider.cs
- FormClosingEvent.cs
- StringResourceManager.cs
- LoginView.cs
- TextEmbeddedObject.cs
- JapaneseLunisolarCalendar.cs
- GuidelineCollection.cs
- PropertyIDSet.cs
- DiagnosticSection.cs
- SqlMultiplexer.cs
- CurrentTimeZone.cs
- GradientSpreadMethodValidation.cs
- DisplayInformation.cs
- WebPartConnectionsConfigureVerb.cs
- TrustManager.cs
- TextEffect.cs