Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / Configuration / System / Configuration / ConfigurationCollectionAttribute.cs / 1 / ConfigurationCollectionAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; using System.Configuration.Internal; using System.Collections; using System.Collections.Specialized; using System.Collections.Generic; using System.IO; using System.Reflection; using System.Security.Permissions; using System.Xml; using System.Globalization; using System.ComponentModel; using System.Security; using System.Text; using System.Configuration; namespace System.Configuration { // This attribute is expected on section properties of type derivied from ConfigurationElementCollection // or on the itself [AttributeUsage(AttributeTargets.Property | AttributeTargets.Class)] public sealed class ConfigurationCollectionAttribute : Attribute { private string _addItemName = null; private string _removeItemName = null; private string _clearItemsName = null; private Type _itemType = null; private ConfigurationElementCollectionType _collectionType = ConfigurationElementCollectionType.AddRemoveClearMap; public ConfigurationCollectionAttribute(Type itemType) { if (itemType == null) { throw new ArgumentNullException("itemType"); } _itemType = itemType; } public Type ItemType { get { return _itemType; } } public string AddItemName { get { if (_addItemName == null) { return ConfigurationElementCollection.DefaultAddItemName; } else { return _addItemName; } } set { if (string.IsNullOrEmpty(value)) { value = null; } _addItemName = value; } } public string RemoveItemName { get { if (_removeItemName == null) { return ConfigurationElementCollection.DefaultRemoveItemName; } else { return _removeItemName; } } set { if (string.IsNullOrEmpty(value)) { value = null; } _removeItemName = value; } } public string ClearItemsName { get { if (_clearItemsName == null) { return ConfigurationElementCollection.DefaultClearItemsName; } else { return _clearItemsName; } } set { if (string.IsNullOrEmpty(value)) { value = null; } _clearItemsName = value; } } public ConfigurationElementCollectionType CollectionType { get { return _collectionType; } set { _collectionType = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; using System.Configuration.Internal; using System.Collections; using System.Collections.Specialized; using System.Collections.Generic; using System.IO; using System.Reflection; using System.Security.Permissions; using System.Xml; using System.Globalization; using System.ComponentModel; using System.Security; using System.Text; using System.Configuration; namespace System.Configuration { // This attribute is expected on section properties of type derivied from ConfigurationElementCollection // or on the itself [AttributeUsage(AttributeTargets.Property | AttributeTargets.Class)] public sealed class ConfigurationCollectionAttribute : Attribute { private string _addItemName = null; private string _removeItemName = null; private string _clearItemsName = null; private Type _itemType = null; private ConfigurationElementCollectionType _collectionType = ConfigurationElementCollectionType.AddRemoveClearMap; public ConfigurationCollectionAttribute(Type itemType) { if (itemType == null) { throw new ArgumentNullException("itemType"); } _itemType = itemType; } public Type ItemType { get { return _itemType; } } public string AddItemName { get { if (_addItemName == null) { return ConfigurationElementCollection.DefaultAddItemName; } else { return _addItemName; } } set { if (string.IsNullOrEmpty(value)) { value = null; } _addItemName = value; } } public string RemoveItemName { get { if (_removeItemName == null) { return ConfigurationElementCollection.DefaultRemoveItemName; } else { return _removeItemName; } } set { if (string.IsNullOrEmpty(value)) { value = null; } _removeItemName = value; } } public string ClearItemsName { get { if (_clearItemsName == null) { return ConfigurationElementCollection.DefaultClearItemsName; } else { return _clearItemsName; } } set { if (string.IsNullOrEmpty(value)) { value = null; } _clearItemsName = value; } } public ConfigurationElementCollectionType CollectionType { get { return _collectionType; } set { _collectionType = 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
- SortKey.cs
- ObjectSecurity.cs
- RIPEMD160Managed.cs
- PrePrepareMethodAttribute.cs
- WSSecurityPolicy12.cs
- GradientBrush.cs
- _TimerThread.cs
- RSAPKCS1KeyExchangeDeformatter.cs
- LexicalChunk.cs
- UriSectionData.cs
- ShutDownListener.cs
- DownloadProgressEventArgs.cs
- ConcurrentStack.cs
- PropertyValueChangedEvent.cs
- _DigestClient.cs
- unitconverter.cs
- CommandManager.cs
- SqlDataReaderSmi.cs
- ArrayHelper.cs
- HatchBrush.cs
- XPathNodeIterator.cs
- Size.cs
- ManifestSignedXml.cs
- SqlMetaData.cs
- IDataContractSurrogate.cs
- StackSpiller.Bindings.cs
- TripleDESCryptoServiceProvider.cs
- MailMessageEventArgs.cs
- _TransmitFileOverlappedAsyncResult.cs
- SqlVersion.cs
- TypeGeneratedEventArgs.cs
- CodeSubDirectory.cs
- GridViewRowEventArgs.cs
- RowUpdatedEventArgs.cs
- _HeaderInfoTable.cs
- FontStyleConverter.cs
- XamlBrushSerializer.cs
- NamespaceInfo.cs
- SmiEventStream.cs
- TypeTypeConverter.cs
- InputMethodStateChangeEventArgs.cs
- IndexedSelectQueryOperator.cs
- CodeStatement.cs
- JoinCqlBlock.cs
- DataGridViewColumnHeaderCell.cs
- UnescapedXmlDiagnosticData.cs
- ValueOfAction.cs
- XmlCustomFormatter.cs
- RangeContentEnumerator.cs
- ErrorStyle.cs
- FormsAuthenticationEventArgs.cs
- CodeExporter.cs
- ToolStripScrollButton.cs
- DeflateInput.cs
- CopyCodeAction.cs
- TextServicesPropertyRanges.cs
- XmlSchemaObject.cs
- EmptyQuery.cs
- FaultDesigner.cs
- MultilineStringConverter.cs
- PictureBoxDesigner.cs
- RightNameExpirationInfoPair.cs
- SessionPageStatePersister.cs
- PropertyGroupDescription.cs
- TabItem.cs
- HyperLinkStyle.cs
- QueryIntervalOp.cs
- RegexWorker.cs
- _OSSOCK.cs
- UInt32Storage.cs
- XmlNavigatorStack.cs
- QilFactory.cs
- TemplateBindingExpressionConverter.cs
- HostSecurityManager.cs
- DesignSurface.cs
- VectorValueSerializer.cs
- WebPartDisplayModeEventArgs.cs
- Roles.cs
- List.cs
- ObjectDataSourceDisposingEventArgs.cs
- MethodToken.cs
- ScrollBar.cs
- Bitmap.cs
- DataGridViewCellErrorTextNeededEventArgs.cs
- WindowsFormsSectionHandler.cs
- CqlBlock.cs
- CompiledAction.cs
- HtmlTable.cs
- WebProxyScriptElement.cs
- XmlObjectSerializerWriteContextComplex.cs
- Figure.cs
- CodeAttachEventStatement.cs
- BuildManager.cs
- TableRow.cs
- ClientTarget.cs
- ListView.cs
- GatewayDefinition.cs
- ImageAnimator.cs
- DbDataAdapter.cs
- XmlSerializerVersionAttribute.cs