TDOMDocument
The TDOMDocument class holds document data according to the Document Object Model (DOM).
Declaration
Excerpted from dom.pas
TDOMDocument = class(TDOMNode_WithChildren)
protected
FIDList: TList;
FRevision: Integer;
FXML11: Boolean;
FImplementation: TDOMImplementation;
function GetDocumentElement: TDOMElement;
function GetDocType: TDOMDocumentType;
function GetNodeType: Integer; override;
function GetNodeName: DOMString; override;
function IndexOfNS(const nsURI: DOMString): Integer;
function FindID(const aID: DOMString; out Index: LongWord): Boolean;
procedure ClearIDList;
public
property DocType: TDOMDocumentType read GetDocType;
property Impl: TDOMImplementation read FImplementation;
property DocumentElement: TDOMElement read GetDocumentElement;
function CreateElement(const tagName: DOMString): TDOMElement; virtual;
function CreateElementBuf(Buf: DOMPChar; Length: Integer): TDOMElement;
function CreateDocumentFragment: TDOMDocumentFragment;
function CreateTextNode(const data: DOMString): TDOMText;
function CreateTextNodeBuf(Buf: DOMPChar; Length: Integer): TDOMText;
function CreateComment(const data: DOMString): TDOMComment;
function CreateCommentBuf(Buf: DOMPChar; Length: Integer): TDOMComment;
function CreateCDATASection(const data: DOMString): TDOMCDATASection; virtual;
function CreateProcessingInstruction(const target, data: DOMString): TDOMProcessingInstruction; virtual;
function CreateAttribute(const name: DOMString): TDOMAttr;
function CreateAttributeBuf(Buf: DOMPChar; Length: Integer): TDOMAttr;
function CreateEntityReference(const name: DOMString): TDOMEntityReference; virtual;
// Free NodeList with TDOMNodeList.Release!
function GetElementsByTagName(const tagname: DOMString): TDOMNodeList;
// DOM level 2 methods
function ImportNode(ImportedNode: TDOMNode; Deep: Boolean): TDOMNode;
function CreateElementNS(const NamespaceURI, QualifiedName: DOMString): TDOMElement;
function CreateAttributeNS(const NamespaceURI, QualifiedName: DOMString): TDOMAttr;
function GetElementsByTagNameNS(const namespaceURI, localName: DOMString): TDOMNodeList;
function GetElementById(const ElementID: DOMString): TDOMElement;
// Extensions to DOM interface:
// TODO: obsolete now, but must check for usage dependencies
constructor Create;
destructor Destroy; override;
function AddID(Attr: TDOMAttr): Boolean;
procedure RemoveID(Attr: TDOMAttr);
end;Back to fcl-xml overview.
See also
External links
From the Free Pascal wiki, page "TDOMDocument", as it stood on 2020-02-29 after a change by Trev, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's Licensing page. If you have concerns about this material, message the admin.
Talk about this page
Nobody has opened a bench for this page yet. Sign in to open one.
