Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Configuration / System / Configuration / IgnoreSection.cs / 1305376 / 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
- formatstringdialog.cs
- TextChangedEventArgs.cs
- ConvertBinder.cs
- PersonalizationStateInfoCollection.cs
- ComponentSerializationService.cs
- VectorValueSerializer.cs
- DependencyPropertyAttribute.cs
- ImageSourceTypeConverter.cs
- ByteStreamMessageEncoder.cs
- EmptyQuery.cs
- CacheMemory.cs
- CustomMenuItemCollection.cs
- DataGridViewAutoSizeColumnsModeEventArgs.cs
- _ScatterGatherBuffers.cs
- ProxyWebPartConnectionCollection.cs
- ScriptIgnoreAttribute.cs
- LogFlushAsyncResult.cs
- MergePropertyDescriptor.cs
- CollectionView.cs
- DesignTimeVisibleAttribute.cs
- HttpContext.cs
- Point3DKeyFrameCollection.cs
- NameValuePermission.cs
- XmlWhitespace.cs
- ObjectConverter.cs
- RC2.cs
- HtmlInputCheckBox.cs
- WizardForm.cs
- SettingsSavedEventArgs.cs
- WebPartChrome.cs
- BindingWorker.cs
- ColumnResult.cs
- RoleGroup.cs
- CqlGenerator.cs
- ConfigurationManagerInternalFactory.cs
- MetafileHeader.cs
- SocketException.cs
- GlobalAllocSafeHandle.cs
- AccessControlList.cs
- IndentedWriter.cs
- ObjectListGeneralPage.cs
- IndexedString.cs
- TransformPattern.cs
- ToolBarButtonClickEvent.cs
- XhtmlStyleClass.cs
- webeventbuffer.cs
- ProcessManager.cs
- UriScheme.cs
- ServiceOperation.cs
- Form.cs
- ArrayTypeMismatchException.cs
- ListBindableAttribute.cs
- IDQuery.cs
- ConvertTextFrag.cs
- ThreadSafeList.cs
- PeerApplication.cs
- Geometry3D.cs
- RawMouseInputReport.cs
- ChangeConflicts.cs
- WpfKnownType.cs
- StringAttributeCollection.cs
- CodeCommentStatementCollection.cs
- SolidColorBrush.cs
- BadImageFormatException.cs
- ConstraintEnumerator.cs
- MessageBox.cs
- HtmlInputPassword.cs
- TextSelectionHighlightLayer.cs
- NonParentingControl.cs
- RelatedCurrencyManager.cs
- FontCacheUtil.cs
- SamlDoNotCacheCondition.cs
- NumericExpr.cs
- WebConfigManager.cs
- InkCanvasFeedbackAdorner.cs
- NativeMethodsCLR.cs
- HttpRuntime.cs
- DesignerValidationSummaryAdapter.cs
- MergeFilterQuery.cs
- ComponentCache.cs
- ForeignKeyFactory.cs
- SuppressMergeCheckAttribute.cs
- NumericUpDown.cs
- ClientSession.cs
- CompatibleIComparer.cs
- CodeDomConfigurationHandler.cs
- RawContentTypeMapper.cs
- DataReaderContainer.cs
- CalendarAutoFormat.cs
- HttpWriter.cs
- QilVisitor.cs
- InternalTypeHelper.cs
- CaretElement.cs
- FormsAuthenticationUser.cs
- AnnotationResourceCollection.cs
- XamlValidatingReader.cs
- CqlIdentifiers.cs
- TraceSection.cs
- FileUtil.cs
- QilValidationVisitor.cs