Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / Configuration / EventMappingSettingsCollection.cs / 1305376 / EventMappingSettingsCollection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.Globalization; using System.IO; using System.Text; using System.ComponentModel; using System.Web.Hosting; using System.Web.Util; using System.Web.Configuration; using System.Web.Management; using System.Web.Compilation; using System.Security.Permissions; [ConfigurationCollection(typeof(EventMappingSettings))] public sealed class EventMappingSettingsCollection : ConfigurationElementCollection { private static ConfigurationPropertyCollection _properties; static EventMappingSettingsCollection() { // Property initialization _properties = new ConfigurationPropertyCollection(); } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } public EventMappingSettingsCollection() { } public new EventMappingSettings this[string key] { get { return (EventMappingSettings)BaseGet(key); } } // public properties public EventMappingSettings this[int index] { get { return (EventMappingSettings)BaseGet(index); } set { if (BaseGet(index) != null) BaseRemoveAt(index); BaseAdd(index, value); } } // Protected Overrides protected override ConfigurationElement CreateNewElement() { return new EventMappingSettings(); } protected override Object GetElementKey(ConfigurationElement element) { return ((EventMappingSettings)element).Name; } // public methods public void Add(EventMappingSettings eventMappingSettings) { BaseAdd(eventMappingSettings); // add to the end of the list and dont overwrite dups! } public void Clear() { BaseClear(); } public void RemoveAt(int index) { BaseRemoveAt(index); } public void Insert(int index, EventMappingSettings eventMappingSettings) { BaseAdd(index, eventMappingSettings); } public int IndexOf(String name) { ConfigurationElement element = BaseGet((Object)name); return (element != null) ? BaseIndexOf(element) : -1; } public void Remove(String name) { BaseRemove(name); } public bool Contains(String name) { return (IndexOf(name) != -1); } } } // 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.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.Globalization; using System.IO; using System.Text; using System.ComponentModel; using System.Web.Hosting; using System.Web.Util; using System.Web.Configuration; using System.Web.Management; using System.Web.Compilation; using System.Security.Permissions; [ConfigurationCollection(typeof(EventMappingSettings))] public sealed class EventMappingSettingsCollection : ConfigurationElementCollection { private static ConfigurationPropertyCollection _properties; static EventMappingSettingsCollection() { // Property initialization _properties = new ConfigurationPropertyCollection(); } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } public EventMappingSettingsCollection() { } public new EventMappingSettings this[string key] { get { return (EventMappingSettings)BaseGet(key); } } // public properties public EventMappingSettings this[int index] { get { return (EventMappingSettings)BaseGet(index); } set { if (BaseGet(index) != null) BaseRemoveAt(index); BaseAdd(index, value); } } // Protected Overrides protected override ConfigurationElement CreateNewElement() { return new EventMappingSettings(); } protected override Object GetElementKey(ConfigurationElement element) { return ((EventMappingSettings)element).Name; } // public methods public void Add(EventMappingSettings eventMappingSettings) { BaseAdd(eventMappingSettings); // add to the end of the list and dont overwrite dups! } public void Clear() { BaseClear(); } public void RemoveAt(int index) { BaseRemoveAt(index); } public void Insert(int index, EventMappingSettings eventMappingSettings) { BaseAdd(index, eventMappingSettings); } public int IndexOf(String name) { ConfigurationElement element = BaseGet((Object)name); return (element != null) ? BaseIndexOf(element) : -1; } public void Remove(String name) { BaseRemove(name); } public bool Contains(String name) { return (IndexOf(name) != -1); } } } // 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
- SecurityVerifiedMessage.cs
- CustomValidator.cs
- Util.cs
- VirtualPathUtility.cs
- TextEditorSelection.cs
- PartitionResolver.cs
- PropertyEntry.cs
- AmbiguousMatchException.cs
- InputProcessorProfiles.cs
- HtmlToClrEventProxy.cs
- WebPartEditVerb.cs
- HeaderedContentControl.cs
- SplitterDesigner.cs
- Vector3DAnimationBase.cs
- invalidudtexception.cs
- BehaviorDragDropEventArgs.cs
- DBBindings.cs
- TextEncodedRawTextWriter.cs
- ValidationHelper.cs
- ToolStripPanelRenderEventArgs.cs
- GridViewCellAutomationPeer.cs
- SimpleHandlerBuildProvider.cs
- Freezable.cs
- DiscreteKeyFrames.cs
- GlyphingCache.cs
- BitmapEffectGroup.cs
- NumberFormatInfo.cs
- PointHitTestParameters.cs
- DecodeHelper.cs
- ShaderEffect.cs
- TargetException.cs
- UnaryNode.cs
- TraceHandlerErrorFormatter.cs
- TransformerConfigurationWizardBase.cs
- SendActivityEventArgs.cs
- CorrelationService.cs
- KeySplineConverter.cs
- _DigestClient.cs
- DetailsViewUpdatedEventArgs.cs
- CallbackCorrelationInitializer.cs
- FaultContractAttribute.cs
- IntegerValidator.cs
- WebPartMinimizeVerb.cs
- MultiByteCodec.cs
- Automation.cs
- FixedDocumentPaginator.cs
- ComponentDesigner.cs
- ElementNotAvailableException.cs
- DataGridViewRow.cs
- Utils.cs
- TraceListener.cs
- Page.cs
- MessageHeaders.cs
- ToolStripDropTargetManager.cs
- ArrayTypeMismatchException.cs
- RegexEditorDialog.cs
- XmlWriterTraceListener.cs
- DesignTimeVisibleAttribute.cs
- RequestCacheEntry.cs
- ApplicationServiceHelper.cs
- ServicesSection.cs
- WCFModelStrings.Designer.cs
- BufferedWebEventProvider.cs
- TableLayoutRowStyleCollection.cs
- DataControlImageButton.cs
- ObjectTag.cs
- PersonalizationStateInfoCollection.cs
- _ProxyChain.cs
- OleDbRowUpdatedEvent.cs
- Point3DValueSerializer.cs
- CategoryNameCollection.cs
- DrawingImage.cs
- GlyphsSerializer.cs
- WebPartZoneBase.cs
- DesignerActionService.cs
- Brush.cs
- XmlUrlEditor.cs
- EventLogPermissionAttribute.cs
- COM2ExtendedTypeConverter.cs
- AutomationPatternInfo.cs
- FrameDimension.cs
- StrongNameHelpers.cs
- ArrayExtension.cs
- unsafeIndexingFilterStream.cs
- SliderAutomationPeer.cs
- ScriptRegistrationManager.cs
- SurrogateEncoder.cs
- StrokeNodeOperations.cs
- CodeTypeReferenceCollection.cs
- ListBoxDesigner.cs
- PeerNameRecordCollection.cs
- AsyncOperationManager.cs
- AutomationProperty.cs
- Attributes.cs
- CollectionContainer.cs
- PropertyEmitter.cs
- ContractHandle.cs
- SymbolPair.cs
- DirectionalLight.cs
- DesignerLabelAdapter.cs