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 / IgnoreSection.cs / 1 / IgnoreSection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Configuration { using System.Xml; sealed public class IgnoreSection : ConfigurationSection { private static ConfigurationPropertyCollection s_properties; string _rawXml = string.Empty; bool _isModified; private static ConfigurationPropertyCollection EnsureStaticPropertyBag() { if (s_properties == null) { ConfigurationPropertyCollection properties = new ConfigurationPropertyCollection(); s_properties = properties; } return s_properties; } public IgnoreSection() { EnsureStaticPropertyBag(); } protected internal override ConfigurationPropertyCollection Properties { get { return EnsureStaticPropertyBag(); } } protected internal override bool IsModified() { return _isModified; } protected internal override void ResetModified() { _isModified = false; } protected internal override void Reset(ConfigurationElement parentSection) { _rawXml = string.Empty; _isModified = false; } protected internal override void DeserializeSection(XmlReader xmlReader) { if (!xmlReader.Read() || xmlReader.NodeType != XmlNodeType.Element) { throw new ConfigurationErrorsException(SR.GetString(SR.Config_base_expected_to_find_element), xmlReader); } _rawXml = xmlReader.ReadOuterXml(); _isModified = true; } protected internal override string SerializeSection(ConfigurationElement parentSection, string name, ConfigurationSaveMode saveMode) { return _rawXml; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Configuration { using System.Xml; sealed public class IgnoreSection : ConfigurationSection { private static ConfigurationPropertyCollection s_properties; string _rawXml = string.Empty; bool _isModified; private static ConfigurationPropertyCollection EnsureStaticPropertyBag() { if (s_properties == null) { ConfigurationPropertyCollection properties = new ConfigurationPropertyCollection(); s_properties = properties; } return s_properties; } public IgnoreSection() { EnsureStaticPropertyBag(); } protected internal override ConfigurationPropertyCollection Properties { get { return EnsureStaticPropertyBag(); } } protected internal override bool IsModified() { return _isModified; } protected internal override void ResetModified() { _isModified = false; } protected internal override void Reset(ConfigurationElement parentSection) { _rawXml = string.Empty; _isModified = false; } protected internal override void DeserializeSection(XmlReader xmlReader) { if (!xmlReader.Read() || xmlReader.NodeType != XmlNodeType.Element) { throw new ConfigurationErrorsException(SR.GetString(SR.Config_base_expected_to_find_element), xmlReader); } _rawXml = xmlReader.ReadOuterXml(); _isModified = true; } protected internal override string SerializeSection(ConfigurationElement parentSection, string name, ConfigurationSaveMode saveMode) { return _rawXml; } } } // 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
- PermissionSetTriple.cs
- CheckBoxList.cs
- NumericPagerField.cs
- EntitySqlQueryCacheEntry.cs
- WindowsMenu.cs
- GroupBoxRenderer.cs
- GeneralEndpointIdentity.cs
- RelationshipDetailsCollection.cs
- WmpBitmapEncoder.cs
- LockedAssemblyCache.cs
- TextDecorationLocationValidation.cs
- ListBox.cs
- HybridDictionary.cs
- SecurityException.cs
- SystemUdpStatistics.cs
- IntegrationExceptionEventArgs.cs
- CryptoApi.cs
- UIElementHelper.cs
- _NegoStream.cs
- Relationship.cs
- PropertyBuilder.cs
- UdpConstants.cs
- WebServiceHost.cs
- StorageRoot.cs
- BufferModeSettings.cs
- WindowVisualStateTracker.cs
- EventData.cs
- ObjectConverter.cs
- Int16KeyFrameCollection.cs
- CommunicationObjectManager.cs
- PropertyMetadata.cs
- Style.cs
- TemplateManager.cs
- DbExpressionVisitor.cs
- ContentOnlyMessage.cs
- ServicePoint.cs
- ServiceProviders.cs
- DictionaryGlobals.cs
- SharedPersonalizationStateInfo.cs
- Control.cs
- Image.cs
- NonSerializedAttribute.cs
- CalendarDesigner.cs
- TextEndOfLine.cs
- EncoderParameter.cs
- TreeWalker.cs
- ToolboxItemCollection.cs
- EncryptedPackage.cs
- ManagementClass.cs
- BrowserInteropHelper.cs
- ListViewGroupItemCollection.cs
- BoundColumn.cs
- TableRow.cs
- HttpGetProtocolImporter.cs
- SortableBindingList.cs
- TextSelection.cs
- RewritingProcessor.cs
- TemplatePartAttribute.cs
- SqlGatherConsumedAliases.cs
- IncomingWebResponseContext.cs
- WebPartRestoreVerb.cs
- CodeTypeParameterCollection.cs
- DependencyPropertyConverter.cs
- CompilerLocalReference.cs
- ServiceHttpModule.cs
- Brush.cs
- HtmlTableCellCollection.cs
- OutputScopeManager.cs
- versioninfo.cs
- SR.cs
- SafeRightsManagementSessionHandle.cs
- SqlDataSourceSelectingEventArgs.cs
- BufferManager.cs
- SeekableReadStream.cs
- SeekableReadStream.cs
- CodeArrayCreateExpression.cs
- SqlRemoveConstantOrderBy.cs
- SafeCancelMibChangeNotify.cs
- RelationshipNavigation.cs
- TextShapeableCharacters.cs
- ItemCheckEvent.cs
- ExpressionBuilder.cs
- TheQuery.cs
- XmlSchemaExternal.cs
- XmlPropertyBag.cs
- PropertyNames.cs
- MenuCommand.cs
- WebPartDisplayModeCollection.cs
- CodeDOMUtility.cs
- NativeCompoundFileAPIs.cs
- SqlConnectionString.cs
- ClipboardProcessor.cs
- DateTimeFormat.cs
- ServerValidateEventArgs.cs
- NavigationPropertyEmitter.cs
- FlowPosition.cs
- localization.cs
- OdbcInfoMessageEvent.cs
- StaticSiteMapProvider.cs
- DocumentViewerBaseAutomationPeer.cs