Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / Xml / System / Xml / Dom / XmlImplementation.cs / 1 / XmlImplementation.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
// [....]
//-----------------------------------------------------------------------------
using System.Globalization;
namespace System.Xml {
// Provides methods for performing operations that are independent of any
// particular instance of the document object model.
public class XmlImplementation {
private XmlNameTable nameTable;
// Initializes a new instance of the XmlImplementation class.
public XmlImplementation() : this( new NameTable() ) {
}
public XmlImplementation( XmlNameTable nt ) {
nameTable = nt;
}
// Test if the DOM implementation implements a specific feature.
public bool HasFeature(string strFeature, string strVersion) {
if (String.Compare("XML", strFeature, StringComparison.OrdinalIgnoreCase) == 0) {
if (strVersion == null || strVersion == "1.0" || strVersion == "2.0")
return true;
}
return false;
}
// Creates a new XmlDocument. All documents created from the same
// XmlImplementation object share the same name table.
public virtual XmlDocument CreateDocument() {
return new XmlDocument( this );
}
internal XmlNameTable NameTable {
get { return nameTable; }
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
// [....]
//-----------------------------------------------------------------------------
using System.Globalization;
namespace System.Xml {
// Provides methods for performing operations that are independent of any
// particular instance of the document object model.
public class XmlImplementation {
private XmlNameTable nameTable;
// Initializes a new instance of the XmlImplementation class.
public XmlImplementation() : this( new NameTable() ) {
}
public XmlImplementation( XmlNameTable nt ) {
nameTable = nt;
}
// Test if the DOM implementation implements a specific feature.
public bool HasFeature(string strFeature, string strVersion) {
if (String.Compare("XML", strFeature, StringComparison.OrdinalIgnoreCase) == 0) {
if (strVersion == null || strVersion == "1.0" || strVersion == "2.0")
return true;
}
return false;
}
// Creates a new XmlDocument. All documents created from the same
// XmlImplementation object share the same name table.
public virtual XmlDocument CreateDocument() {
return new XmlDocument( this );
}
internal XmlNameTable NameTable {
get { return nameTable; }
}
}
}
// 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
- FunctionMappingTranslator.cs
- SmiRequestExecutor.cs
- AdornerPresentationContext.cs
- BufferBuilder.cs
- InteropAutomationProvider.cs
- DocumentAutomationPeer.cs
- DrawingCollection.cs
- followingquery.cs
- DATA_BLOB.cs
- XMLDiffLoader.cs
- LazyTextWriterCreator.cs
- DataServiceRequest.cs
- ItemContainerGenerator.cs
- SafeHandles.cs
- BamlResourceSerializer.cs
- BitmapEffectInput.cs
- TextReturnReader.cs
- BulletChrome.cs
- OdbcParameter.cs
- SByteConverter.cs
- ViewManager.cs
- CommonRemoteMemoryBlock.cs
- QueryOperatorEnumerator.cs
- StateMachineSubscriptionManager.cs
- KeySplineConverter.cs
- EventManager.cs
- PersonalizablePropertyEntry.cs
- MetadataItemEmitter.cs
- Registry.cs
- ControlCodeDomSerializer.cs
- DefaultValueConverter.cs
- ApplicationId.cs
- NoneExcludedImageIndexConverter.cs
- ValueOfAction.cs
- MimeTypePropertyAttribute.cs
- unsafenativemethodsother.cs
- SqlGenerator.cs
- DataServiceException.cs
- PenLineJoinValidation.cs
- TextEffectResolver.cs
- InstanceLockedException.cs
- MailMessageEventArgs.cs
- ManagementEventWatcher.cs
- TextSelectionHighlightLayer.cs
- sqlinternaltransaction.cs
- NavigatorOutput.cs
- Geometry3D.cs
- TextContainerHelper.cs
- ValueOfAction.cs
- BackgroundFormatInfo.cs
- ToolStripItemCollection.cs
- Interop.cs
- DataGridViewColumnHeaderCell.cs
- MdImport.cs
- COM2FontConverter.cs
- ScriptRegistrationManager.cs
- XmlQueryContext.cs
- UiaCoreTypesApi.cs
- Point4D.cs
- NavigationPropertyEmitter.cs
- CompoundFileIOPermission.cs
- AttributeCollection.cs
- ComponentGuaranteesAttribute.cs
- smtppermission.cs
- MultiAsyncResult.cs
- DataBoundControlDesigner.cs
- SafeProcessHandle.cs
- FacetDescription.cs
- BaseHashHelper.cs
- BuildProvider.cs
- DeferredReference.cs
- XmlArrayItemAttribute.cs
- SimpleRecyclingCache.cs
- XsdDataContractExporter.cs
- MarkupExtensionParser.cs
- LinqDataSourceEditData.cs
- CodeStatementCollection.cs
- PathData.cs
- OracleTimeSpan.cs
- OutputCacheSettings.cs
- BlurEffect.cs
- Message.cs
- X509Certificate2Collection.cs
- HtmlInputReset.cs
- GatewayDefinition.cs
- HttpWriter.cs
- LicenseException.cs
- OneOfElement.cs
- TableLayout.cs
- ContentPlaceHolder.cs
- ObjectRef.cs
- DataGridViewColumn.cs
- PageStatePersister.cs
- XmlReaderDelegator.cs
- DbUpdateCommandTree.cs
- PerformanceCounterCategory.cs
- ActiveXContainer.cs
- SiteMapDataSource.cs
- CngProperty.cs
- CharEntityEncoderFallback.cs