Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / Configuration / IgnoreDeviceFilterElementCollection.cs / 1305376 / IgnoreDeviceFilterElementCollection.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Web.Configuration {
using System;
using System.Configuration;
using System.Collections.Specialized;
using System.Collections;
using System.Diagnostics.CodeAnalysis;
using System.IO;
using System.Security.Permissions;
using System.Text;
using System.Threading;
using System.Web.Util;
using System.Web.UI;
using System.Web.Compilation;
using System.Web.Configuration;
using System.Xml;
[ConfigurationCollection(typeof(IgnoreDeviceFilterElement), AddItemName = "filter",
CollectionType = ConfigurationElementCollectionType.BasicMap)]
public sealed class IgnoreDeviceFilterElementCollection : ConfigurationElementCollection {
private static readonly ConfigurationPropertyCollection _properties;
static IgnoreDeviceFilterElementCollection() {
_properties = new ConfigurationPropertyCollection();
}
public IgnoreDeviceFilterElementCollection()
: base(StringComparer.OrdinalIgnoreCase) {
}
protected override ConfigurationPropertyCollection Properties {
get {
return _properties;
}
}
public void Add(IgnoreDeviceFilterElement deviceFilter) {
BaseAdd(deviceFilter);
}
public void Remove(string name) {
BaseRemove(name);
}
public void Remove(IgnoreDeviceFilterElement deviceFilter) {
BaseRemove(GetElementKey(deviceFilter));
}
public void RemoveAt(int index) {
BaseRemoveAt(index);
}
public new IgnoreDeviceFilterElement this[string name] {
get {
return (IgnoreDeviceFilterElement)BaseGet(name);
}
}
public IgnoreDeviceFilterElement this[int index] {
get {
return (IgnoreDeviceFilterElement)BaseGet(index);
}
set {
if (BaseGet(index) != null) {
BaseRemoveAt(index);
}
BaseAdd(index, value);
}
}
public void Clear() {
BaseClear();
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
protected override ConfigurationElement CreateNewElement() {
return new IgnoreDeviceFilterElement();
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
protected override Object GetElementKey(ConfigurationElement element) {
return ((IgnoreDeviceFilterElement)element).Name;
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
protected override string ElementName {
get {
return "filter";
}
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
public override ConfigurationElementCollectionType CollectionType {
get {
return ConfigurationElementCollectionType.BasicMap;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Web.Configuration {
using System;
using System.Configuration;
using System.Collections.Specialized;
using System.Collections;
using System.Diagnostics.CodeAnalysis;
using System.IO;
using System.Security.Permissions;
using System.Text;
using System.Threading;
using System.Web.Util;
using System.Web.UI;
using System.Web.Compilation;
using System.Web.Configuration;
using System.Xml;
[ConfigurationCollection(typeof(IgnoreDeviceFilterElement), AddItemName = "filter",
CollectionType = ConfigurationElementCollectionType.BasicMap)]
public sealed class IgnoreDeviceFilterElementCollection : ConfigurationElementCollection {
private static readonly ConfigurationPropertyCollection _properties;
static IgnoreDeviceFilterElementCollection() {
_properties = new ConfigurationPropertyCollection();
}
public IgnoreDeviceFilterElementCollection()
: base(StringComparer.OrdinalIgnoreCase) {
}
protected override ConfigurationPropertyCollection Properties {
get {
return _properties;
}
}
public void Add(IgnoreDeviceFilterElement deviceFilter) {
BaseAdd(deviceFilter);
}
public void Remove(string name) {
BaseRemove(name);
}
public void Remove(IgnoreDeviceFilterElement deviceFilter) {
BaseRemove(GetElementKey(deviceFilter));
}
public void RemoveAt(int index) {
BaseRemoveAt(index);
}
public new IgnoreDeviceFilterElement this[string name] {
get {
return (IgnoreDeviceFilterElement)BaseGet(name);
}
}
public IgnoreDeviceFilterElement this[int index] {
get {
return (IgnoreDeviceFilterElement)BaseGet(index);
}
set {
if (BaseGet(index) != null) {
BaseRemoveAt(index);
}
BaseAdd(index, value);
}
}
public void Clear() {
BaseClear();
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
protected override ConfigurationElement CreateNewElement() {
return new IgnoreDeviceFilterElement();
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
protected override Object GetElementKey(ConfigurationElement element) {
return ((IgnoreDeviceFilterElement)element).Name;
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
protected override string ElementName {
get {
return "filter";
}
}
[SuppressMessage("Microsoft.Security", "CA2123:OverrideLinkDemandsShouldBeIdenticalToBase", Justification = "Can't modify the base class.")]
public override ConfigurationElementCollectionType CollectionType {
get {
return ConfigurationElementCollectionType.BasicMap;
}
}
}
}
// 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
- Timeline.cs
- TriggerAction.cs
- SqlConnectionString.cs
- BaseWebProxyFinder.cs
- SafeProcessHandle.cs
- Constant.cs
- EventDescriptor.cs
- DataBindingList.cs
- Throw.cs
- SessionStateSection.cs
- PropertyDescriptorGridEntry.cs
- Table.cs
- TextServicesPropertyRanges.cs
- CompilationRelaxations.cs
- ImageDrawing.cs
- SqlNotificationRequest.cs
- AssemblyHash.cs
- ReliableOutputConnection.cs
- CompiledAction.cs
- OracleInternalConnection.cs
- EntityDescriptor.cs
- Types.cs
- DateTimeValueSerializerContext.cs
- CopyCodeAction.cs
- ArcSegment.cs
- TextServicesCompartmentContext.cs
- MediaTimeline.cs
- ContextMarshalException.cs
- SiteMapNodeItem.cs
- OletxEnlistment.cs
- UrlPath.cs
- KeyValueConfigurationElement.cs
- DataGridViewRowPrePaintEventArgs.cs
- UInt64Storage.cs
- GeometryCollection.cs
- XhtmlBasicTextBoxAdapter.cs
- TextEditorContextMenu.cs
- PointHitTestResult.cs
- UIntPtr.cs
- ResourceReferenceExpression.cs
- DocumentSequence.cs
- DataSourceControl.cs
- X509CertificateStore.cs
- WebPartConnectionsDisconnectVerb.cs
- InfoCardArgumentException.cs
- PointAnimation.cs
- MediaSystem.cs
- XmlAttributeCache.cs
- DoubleAnimationUsingPath.cs
- DetailsViewInsertedEventArgs.cs
- TextTreeUndoUnit.cs
- ListViewUpdatedEventArgs.cs
- XPathDocumentIterator.cs
- ConfigsHelper.cs
- SizeLimitedCache.cs
- Vector3DCollection.cs
- OpacityConverter.cs
- TabItem.cs
- SqlSelectStatement.cs
- DataObjectCopyingEventArgs.cs
- DataGridRowHeaderAutomationPeer.cs
- FixedSOMTableRow.cs
- MinMaxParagraphWidth.cs
- SQLByte.cs
- TrustLevelCollection.cs
- OleDbRowUpdatedEvent.cs
- BufferedWebEventProvider.cs
- COM2PropertyBuilderUITypeEditor.cs
- SoapSchemaImporter.cs
- DataControlField.cs
- XPathAxisIterator.cs
- SpotLight.cs
- CodeRegionDirective.cs
- FileSystemInfo.cs
- WebPartConnection.cs
- PrivacyNoticeElement.cs
- CodeCatchClauseCollection.cs
- EnvelopedPkcs7.cs
- Types.cs
- WebErrorHandler.cs
- BitmapEffect.cs
- HttpListener.cs
- MemoryStream.cs
- prompt.cs
- Util.cs
- prompt.cs
- UnicodeEncoding.cs
- ProfileSettings.cs
- CompilerInfo.cs
- Image.cs
- XmlMemberMapping.cs
- SchemaManager.cs
- InkCanvasSelectionAdorner.cs
- XmlBinaryReaderSession.cs
- SafePEFileHandle.cs
- CustomLineCap.cs
- WebHttpBindingElement.cs
- ConfigurationCollectionAttribute.cs
- ApplicationGesture.cs
- WithParamAction.cs