Deal with old libxml incompatibilities.
[htmlpurifier.git] / library / HTMLPurifier / Node.php
blob3995fec9fe65c0309114c5dfea1cb184886be653
1 <?php
3 /**
4 * Abstract base node class that all others inherit from.
6 * Why do we not use the DOM extension? (1) It is not always available,
7 * (2) it has funny constraints on the data it can represent,
8 * whereas we want a maximally flexible representation, and (3) its
9 * interface is a bit cumbersome.
11 abstract class HTMLPurifier_Node
13 /**
14 * Line number of the start token in the source document
15 * @type int
17 public $line;
19 /**
20 * Column number of the start token in the source document. Null if unknown.
21 * @type int
23 public $col;
25 /**
26 * Lookup array of processing that this token is exempt from.
27 * Currently, valid values are "ValidateAttributes".
28 * @type array
30 public $armor = array();
32 /**
33 * When true, this node should be ignored as non-existent.
35 * Who is responsible for ignoring dead nodes? FixNesting is
36 * responsible for removing them before passing on to child
37 * validators.
39 public $dead = false;
41 /**
42 * Returns a pair of start and end tokens, where the end token
43 * is null if it is not necessary. Does not include children.
44 * @type array
46 abstract public function toTokenPair();
49 // vim: et sw=4 sts=4