Sign in Join
FPDoc Onlineexperiment

TDOMParser class

In unit Laz2_XMLRead

Implements a parser used to de-serialize XML content into DOM Nodes.

Declaration

pascal
TDOMParser = class(TObject)

Inheritance

  1. TDOMParser
  2. TObject

Description

TDOMParser is a class which implements a DOM Parser component. TDOMParser provides methods to parse XML content specified by its URI or using an XML input source. TDOMParser creates DOM nodes needed to represent the XML content, and stores the nodes in a TXMLDocument instance or a DOM content node.

Use the Options property to enable specific features or behavior in the parser. Of particular importance is the Validate, which enables validation when processing XML content in the parser.

DOM (Document Object Model) does not specify an interface for a parser class. TDOMParser utilizes the TXMLReader class to perform the actions required to convert and de-serialize XML content. TXMLReader closely resembles the XMLReader class defined in SAX (Simple API for XML), but uses its own methods instead of Handler class instances to process various DOM Node types. TXMLReader is compliant with the XML 1.0 specification.

See also

Properties

OptionspublicOptions for the DOM parser.

Methods

CreatepublicConstructor for the class instance.
DestroypublicDestructor for the class instance.
ParsepublicParses the input source and updates the specified XML document.
ParseUripublicParses XML content from the specified URI into the XML document.
ParseWithContextpublicParses the XML input source into the specified DOM context Node.

Events

OnErrorpublicEvent handler signalled when an error occurs while reading XML content.

Inherited

From TObject (40)

AfterConstruction BeforeDestruction CheckDisposed ClassInfo ClassName ClassNameIs ClassParent ClassType CleanupInstance DefaultHandler DefaultHandlerStr Dispatch DispatchStr Disposed DisposeOf Equals FieldAddress Free FreeInstance GetDisposed GetHashCode GetInterface GetInterfaceByStr GetInterfaceEntry GetInterfaceEntryByStr GetInterfaceTable GetInterfaceWeak GetLastCastErrorInfo InheritsFrom InitInstance InstanceSize MethodAddress MethodName newinstance QualifiedClassName SafeCallException StringMessageTable SystemHasExtendedRTTI ToString UnitName

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.