XmlWriterSettings Class

XmlWriterSettings Class

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Specifies a set of features to support on the XmlWriter object created by the XmlWriter::Create method.

System::Object
  System.Xml::XmlWriterSettings

Namespace:  System.Xml
Assembly:  System.Xml (in System.Xml.dll)

No code example is currently available or this language may not be supported.

The XmlWriterSettings type exposes the following members.

  NameDescription
Public methodXmlWriterSettingsInitializes a new instance of the XmlWriterSettings class.
Top

  NameDescription
Public propertyAsyncGets or sets a value that indicates whether asynchronous XmlWriter methods can be used on a particular XmlWriter instance.
Public propertyCheckCharactersGets or sets a value indicating whether to do character checking.
Public propertyCloseOutputGets or sets a value indicating whether the XmlWriter should also close the underlying stream or TextWriter when the Close method is called.
Public propertyConformanceLevelGets or sets the level of conformance which the XmlWriter complies with.
Public propertyEncodingGets or sets the text encoding to use.
Public propertyIndentGets or sets a value indicating whether to indent elements.
Public propertyIndentCharsGets or sets the character string to use when indenting. This setting is used when the Indent property is set to true.
Public propertyNamespaceHandlingGets or sets the NamespaceHandling enumeration used to specify whether to remove duplicate namespace declarations in the XmlWriter. For the duplicate namespace to be removed, the prefix and the namespace have to match.
Public propertyNewLineCharsGets or sets the character string to use for line breaks.
Public propertyNewLineHandlingGets or sets a value indicating whether to normalize line breaks in the output.
Public propertyNewLineOnAttributesGets or sets a value indicating whether to write attributes on a new line.
Public propertyOmitXmlDeclarationGets or sets a value indicating whether to write an XML declaration.
Public propertyWriteEndDocumentOnCloseGets or sets a value that indicates whether the XmlWriter will add closing tags to all unclosed element tags when the Close() method is called.
Top

  NameDescription
Public methodCloneCreates a copy of the XmlWriterSettings instance.
Public methodEquals(Object)Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetHashCodeServes as a hash function for a particular type. (Inherited from Object.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodResetResets the members of the settings class to their default values.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top

In the Microsoft .NET Framework 2.0 release, the Create method is the preferred mechanism for obtaining XmlWriter instances. The Create method uses the XmlWriterSettings class to specify which features to implement in the created XmlWriter object.

No code example is currently available or this language may not be supported.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Show:
© 2017 Microsoft