Class TTreeAttribute

Unit

Declaration

type TTreeAttribute = class(TTreeNode)

Description

No description available, ancestor TTreeNode description follows

This class representates an element of the html file

It is stored in an unusual tree representation: All elements form a linked list and the next element is the first children, or if there is none, the next node on the same level, or if there is none, the closing tag of the current parent.
E.g. an XML file like <foo><bar>x</bar></foo> is stored as a quadro-linked list:

  /---------------------------------\
  |         |  -----------          |                                   link to parent (for faster access, it would work without it)
 \|/        | \|/        |          |
  '            '
<foo> <---> <bar>  <---> x <--->  </bar>  <--->  </foo>                 double linked list of tags (previous link again for faster access, a single linked list would work as well)
  .           .                     .               .
 /|\         /|\                   /|\             /|\
  |           -----------------------               |                   single linked of corresponding node
  ---------------------------------------------------

There are functions (getNextSibling, getFirstChild, findNext, ...) to access it like a regular tree, but it is easier and faster to work directly with the list.
Some invariants: (SO: set of opening tags in sequence)
∀a \in SO: a < a.reverse
∀a,b \in SO: a < b < a.reverse => a < b.reverse < a.reverse

Attributes should be accessed with the getAttribute or getAttributeTry method. Or you can enumerate them all for attrib in attributes, if attributes is not nil.
#)

Hierarchy

Overview

Fields

Public realvalue: string;

Methods

Public function isNamespaceNode: boolean;
Public function toNamespaceObject: TNamespace;
Public procedure setDataTypeHack(i: integer);
Public function getDataTypeHack(): integer;

Description

Fields

Public realvalue: string;
 

Methods

Public function isNamespaceNode: boolean;
 
Public function toNamespaceObject: TNamespace;
 
Public procedure setDataTypeHack(i: integer);
 
Public function getDataTypeHack(): integer;
 

Generated by PasDoc 0.16.0.