ILIAS  release_4-4 Revision
HTMLPurifier_Token Class Reference

Abstract base token class that all others inherit from. More...

+ Inheritance diagram for HTMLPurifier_Token:
+ Collaboration diagram for HTMLPurifier_Token:

Public Member Functions

 __get ($n)
 
 position ($l=null, $c=null)
 Sets the position of the token in the source document. More...
 
 rawPosition ($l, $c)
 Convenience function for DirectLex settings line/col position. More...
 

Data Fields

 $line
 Line number node was on in source document. More...
 
 $col
 Column of line node was on in source document. More...
 
 $armor = array()
 Lookup array of processing that this token is exempt from. More...
 
 $skip
 Used during MakeWellFormed. More...
 
 $rewind
 
 $carryover
 

Detailed Description

Abstract base token class that all others inherit from.

Definition at line 6 of file Token.php.

Member Function Documentation

◆ __get()

HTMLPurifier_Token::__get (   $n)

Definition at line 24 of file Token.php.

References $n.

24  {
25  if ($n === 'type') {
26  trigger_error('Deprecated type property called; use instanceof', E_USER_NOTICE);
27  switch (get_class($this)) {
28  case 'HTMLPurifier_Token_Start': return 'start';
29  case 'HTMLPurifier_Token_Empty': return 'empty';
30  case 'HTMLPurifier_Token_End': return 'end';
31  case 'HTMLPurifier_Token_Text': return 'text';
32  case 'HTMLPurifier_Token_Comment': return 'comment';
33  default: return null;
34  }
35  }
36  }
$n
Definition: RandomTest.php:80

◆ position()

HTMLPurifier_Token::position (   $l = null,
  $c = null 
)

Sets the position of the token in the source document.

Definition at line 41 of file Token.php.

41  {
42  $this->line = $l;
43  $this->col = $c;
44  }

◆ rawPosition()

HTMLPurifier_Token::rawPosition (   $l,
  $c 
)

Convenience function for DirectLex settings line/col position.

Definition at line 49 of file Token.php.

49  {
50  if ($c === -1) $l++;
51  $this->line = $l;
52  $this->col = $c;
53  }

Field Documentation

◆ $armor

HTMLPurifier_Token::$armor = array()

Lookup array of processing that this token is exempt from.

Currently, valid values are "ValidateAttributes" and "MakeWellFormed_TagClosedError"

Definition at line 15 of file Token.php.

Referenced by HTMLPurifier_Token_Tag\__construct().

◆ $carryover

HTMLPurifier_Token::$carryover

Definition at line 22 of file Token.php.

◆ $col

HTMLPurifier_Token::$col

Column of line node was on in source document.

Null if unknown.

Definition at line 8 of file Token.php.

Referenced by HTMLPurifier_Token_Comment\__construct(), HTMLPurifier_Token_Text\__construct(), and HTMLPurifier_Token_Tag\__construct().

◆ $line

HTMLPurifier_Token::$line

Line number node was on in source document.

Null if unknown.

Definition at line 7 of file Token.php.

Referenced by HTMLPurifier_Token_Comment\__construct(), HTMLPurifier_Token_Text\__construct(), and HTMLPurifier_Token_Tag\__construct().

◆ $rewind

HTMLPurifier_Token::$rewind

Definition at line 21 of file Token.php.

◆ $skip

HTMLPurifier_Token::$skip

Used during MakeWellFormed.

Definition at line 20 of file Token.php.


The documentation for this class was generated from the following file: