Enumeration

NSXMLNodeOptions

These constants are input and output options for all NSXMLNode objects (unless otherwise indicated), including NSXMLDocument objects. You can specify these options in the NSXMLNode methods initWithKind:options: and XMLStringWithOptions:.

Declaration

typedef enum NSXMLNodeOptions : NSUInteger {
    ...
} NSXMLNodeOptions;

Overview

The options with “Preserve” in their names are applicable only when external sources of XML are parsed; they have no effect on node objects that are programmatically created. Other options are used in initialization and output methods of NSXMLDocument; see the NSXMLDocument reference documentation for details.

Topics

Constants

NSXMLDocumentIncludeContentTypeDeclaration

Includes a content type declaration for HTML or XHTML in the output of the document.

NSXMLDocumentTidyHTML

Formats HTML into valid XHTML during processing of the document.

NSXMLDocumentTidyXML

Changes malformed XML into valid XML during processing of the document.

NSXMLDocumentValidate

Validates this document against its DTD (internal or external) or XML Schema.

NSXMLDocumentXInclude

Replaces all XInclude nodes in the document with the nodes referred to.

NSXMLNodeCompactEmptyElement

Requests that an element should be contracted when empty; for example, <flag/>.

NSXMLNodeExpandEmptyElement

Requests that an element should be expanded when empty; for example, <flag></flag>. This is the default.

NSXMLNodeIsCDATA

Specifies that a text node contains and is written out as a CDATA section.

NSXMLNodeLoadExternalEntitiesAlways

Requests that external entities are always loaded.

NSXMLNodeLoadExternalEntitiesNever

Requests that external entities are never loaded.

NSXMLNodeLoadExternalEntitiesSameOriginOnly

Requests that external entities are always loaded and only applies when a URL has been provided.

NSXMLNodeOptionsNone

No options are requested for this input or output action.

NSXMLNodePreserveAttributeOrder

Requests that NSXMLNode preserve the order of attributes as in the source XML.

NSXMLNodePreserveCDATA

Requests that NSXMLNode preserve CDATA blocks where defined in the input XML.

NSXMLNodePreserveCharacterReferences

Specifies that character references (&#nnn;) should not be resolved for XML output of this node.

NSXMLNodePreserveDTD

Specifies that declarations in a DTD should be preserved until it the DTD is modified. For example, parameter entities are by default expanded; with this option, they are written out as they originally occur in the DTD.

NSXMLNodePreserveEmptyElements

Specifies that empty elements in the input XML be preserved in their contracted or expanded form.

NSXMLNodePreserveEntities

Specifies that entities (&xyz;) should not be resolved for XML output of this node.

NSXMLNodePreserveNamespaceOrder

Requests NSXML to preserve the order of namespace URI definitions as in the source XML.

NSXMLNodePreservePrefixes

Requests NSXMLNode not to choose prefixes based on the closest namespace URI definition.

NSXMLNodePreserveQuotes

Specifies that the quoting style used in the input XML (single or double quotes) be preserved.

NSXMLNodePreserveWhitespace

Requests NSXMLNode to preserve whitespace characters (such as tabs and carriage returns) in the XML source that are not part of node content.

NSXMLNodePrettyPrint

Print this node with extra space for readability. (Output)

NSXMLNodeUseDoubleQuotes

Requests that NSXML use double quotes for the value of an attribute or namespace node. This is the default.

NSXMLNodeUseSingleQuotes

Requests that NSXML use single quotes for the value of an attribute or namespace node.