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
- EntityContainerEntitySetDefiningQuery.cs
- BoundsDrawingContextWalker.cs
- GraphicsContainer.cs
- TemplatePartAttribute.cs
- ClientScriptManager.cs
- SecurityElement.cs
- ParentControlDesigner.cs
- BezierSegment.cs
- X509Utils.cs
- XmlChildEnumerator.cs
- Preprocessor.cs
- UnknownBitmapEncoder.cs
- SqlClientFactory.cs
- TextViewElement.cs
- SqlUtils.cs
- GifBitmapEncoder.cs
- SecurityException.cs
- IgnoreSectionHandler.cs
- QuaternionRotation3D.cs
- WindowsFormsHostAutomationPeer.cs
- InvokeProviderWrapper.cs
- _NetRes.cs
- documentsequencetextview.cs
- WindowsRegion.cs
- Regex.cs
- CompilerState.cs
- JournalNavigationScope.cs
- TextModifierScope.cs
- SqlConnectionString.cs
- ManagedWndProcTracker.cs
- TraceHandlerErrorFormatter.cs
- EntityDataReader.cs
- TypeBuilder.cs
- PackageDigitalSignatureManager.cs
- LabelLiteral.cs
- FormViewInsertEventArgs.cs
- PenThreadWorker.cs
- DataFormat.cs
- XmlDataImplementation.cs
- CriticalExceptions.cs
- Renderer.cs
- URLAttribute.cs
- TrackingStringDictionary.cs
- RSAOAEPKeyExchangeFormatter.cs
- CodeMethodReturnStatement.cs
- DbDataRecord.cs
- ResourceContainer.cs
- MenuBase.cs
- DataGridViewImageCell.cs
- GuidConverter.cs
- StringUtil.cs
- PropertyManager.cs
- FontStyles.cs
- LinqDataSourceUpdateEventArgs.cs
- EventMetadata.cs
- PenLineJoinValidation.cs
- Focus.cs
- WindowsListView.cs
- OrthographicCamera.cs
- BasicViewGenerator.cs
- PolicyException.cs
- MemberPath.cs
- TraceInternal.cs
- RemotingException.cs
- _DomainName.cs
- PolyBezierSegmentFigureLogic.cs
- XamlFilter.cs
- ExitEventArgs.cs
- sqlpipe.cs
- XPathNavigatorReader.cs
- OptionalRstParameters.cs
- DbParameterCollectionHelper.cs
- _RequestCacheProtocol.cs
- ScaleTransform.cs
- EndpointAddressMessageFilterTable.cs
- XmlCDATASection.cs
- Point4D.cs
- ProcessModelSection.cs
- ExtensionFile.cs
- TreeViewImageKeyConverter.cs
- Error.cs
- Page.cs
- XmlDocumentSchema.cs
- IssuerInformation.cs
- FixedSOMTextRun.cs
- GrowingArray.cs
- RtfFormatStack.cs
- DataGridColumn.cs
- SmiTypedGetterSetter.cs
- TextServicesContext.cs
- ChannelAcceptor.cs
- IsolatedStorageFile.cs
- DetailsViewRowCollection.cs
- XamlBrushSerializer.cs
- WebPartVerb.cs
- PlainXmlWriter.cs
- HttpCachePolicy.cs
- PerformanceCounterManager.cs
- CodeTypeMemberCollection.cs
- parserscommon.cs