HTML visitor for the RST AST.
Source for this file: /Document/src/document/rst/visitor/xhtml.php
ezcDocumentRstVisitor | --ezcDocumentRstXhtmlVisitor
Version: | //autogen// |
Child Class | Description |
---|---|
ezcDocumentRstXhtmlBodyVisitor | HTML visitor for the RST AST, which only produces contents to be embedded somewhere into the body of an existing HTML document. |
From ezcDocumentRstVisitor: | |
---|---|
ezcDocumentRstVisitor::DUBLICATE
|
Duplicate reference target. Will throw an error on use. |
ezcDocumentRstVisitor::UNUSED
|
Unused reference target |
ezcDocumentRstVisitor::USED
|
Used reference target |
protected array |
$complexVisitMapping
= array(
Mapping of class names to internal visitors for the respective nodes. |
protected int |
$depth
= 0
Current depth in document. |
protected DOMDocument |
$document
DOM document |
protected DOMElement |
$head
Reference to head node |
protected ezcDocumentHtmlConverterOptions |
$options
HTML rendering options |
protected array |
$simpleVisitMapping
= array(
Direct mapping of AST node class names to docbook element names. |
protected array |
$skipNodes
= array(
Array with nodes, which can be ignored during the transformation process, they only provide additional information during preprocessing. |
From ezcDocumentRstVisitor | |
---|---|
protected |
ezcDocumentRstVisitor::$anonymousReferenceCounter
|
protected |
ezcDocumentRstVisitor::$anonymousReferences
|
protected |
ezcDocumentRstVisitor::$ast
|
protected |
ezcDocumentRstVisitor::$errors
|
protected |
ezcDocumentRstVisitor::$footnoteCounter
|
protected |
ezcDocumentRstVisitor::$footnotes
|
protected |
ezcDocumentRstVisitor::$footnoteSymbols
|
protected |
ezcDocumentRstVisitor::$namedExternalReferences
|
protected |
ezcDocumentRstVisitor::$path
|
protected |
ezcDocumentRstVisitor::$referenceCounter
|
protected |
ezcDocumentRstVisitor::$references
|
protected |
ezcDocumentRstVisitor::$rst
|
protected |
ezcDocumentRstVisitor::$substitutions
|
protected |
ezcDocumentRstVisitor::$usedIDs
|
public void |
__construct(
$document
, $path
)
Create visitor from RST document handler. |
protected void |
addStylesheets(
$head
)
Add stylesheets to header |
public string |
escapeUrl(
$url
)
Escape all special characters in URIs |
protected string |
generateFootnoteReferenceLink(
$name
, $number
)
Generate footnote reference link |
public mixed |
visit(
$ast
)
Docarate RST AST |
protected void |
visitAnonymousReference(
$root
, $node
)
Visit anonomyous reference node |
protected void |
visitBlockquote(
$root
, $node
)
Visit blockquotes |
protected void |
visitBulletList(
$root
, $node
)
Visit bullet lists |
protected void |
visitComment(
$root
, $node
)
Visit comment |
protected void |
visitDefinitionListItem(
$root
, $node
)
Visit definition list item |
protected void |
visitDirective(
$root
, $node
)
Visit directive |
protected void |
visitEnumeratedList(
$root
, $node
)
Visit enumerated lists |
protected void |
visitExternalReference(
$root
, $node
)
Visit external reference node |
protected void |
visitFieldListItem(
$root
, $node
)
Visit field list item |
protected void |
visitFootnote(
$root
, $node
)
Visit footnote |
protected void |
visitInlineTarget(
$root
, $node
)
Visit inline target node |
protected void |
visitInternalFootnoteReference(
$root
, $node
)
Visit internal reference node |
protected void |
visitInterpretedTextNode(
$root
, $node
)
Visit interpreted text node markup |
protected void |
visitLineBlock(
$root
, $node
)
Visit line block |
protected void |
visitLineBlockLine(
$root
, $node
)
Visit line block line |
protected void |
visitNode(
$root
, $node
)
Visit single AST node |
protected void |
visitSection(
$root
, $node
)
Visit section node |
protected void |
visitTableCell(
$root
, $node
)
Visit table cell |
From ezcDocumentRstVisitor | |
---|---|
public void |
ezcDocumentRstVisitor::__construct()
Create visitor from RST document handler. |
protected void |
ezcDocumentRstVisitor::addFootnote()
Add footnote |
protected void |
ezcDocumentRstVisitor::aggregateListItems()
Aggregate list items |
protected string |
ezcDocumentRstVisitor::calculateId()
Get a valid identifier string |
protected string |
ezcDocumentRstVisitor::calculateUniqueId()
Calculate unique ID |
protected bool |
ezcDocumentRstVisitor::compareListType()
Compare two list items |
public string |
ezcDocumentRstVisitor::getAnonymousReferenceTarget()
Get anonymous reference target |
public array |
ezcDocumentRstVisitor::getErrors()
Return list of errors occured during visiting the document. |
public string |
ezcDocumentRstVisitor::getNamedExternalReference()
Return named external reference target |
public ezcDocumentRstFootnoteNode |
ezcDocumentRstVisitor::hasFootnoteTarget()
Check for internal footnote reference target |
public string |
ezcDocumentRstVisitor::hasReferenceTarget()
Check for internal reference target |
public string |
ezcDocumentRstVisitor::nodeToString()
Transform a node tree into a string |
protected void |
ezcDocumentRstVisitor::preProcessAst()
Pre process AST |
protected void |
ezcDocumentRstVisitor::substitute()
Get substitution contents |
protected string |
ezcDocumentRstVisitor::tokenListToString()
Get string from token list. |
public void |
ezcDocumentRstVisitor::triggerError()
Trigger visitor error |
public mixed |
ezcDocumentRstVisitor::visit()
Docarate RST AST |
protected void |
ezcDocumentRstVisitor::visitChildren()
Visit children |
protected void |
ezcDocumentRstVisitor::visitSubstitutionReference()
Visit substitution reference node |
protected void |
ezcDocumentRstVisitor::visitText()
Visit text node |
Create visitor from RST document handler.
Name | Type | Description |
---|---|---|
$document |
ezcDocumentRst | |
$path |
string |
Method | Description |
---|---|
ezcDocumentRstVisitor::__construct() |
Create visitor from RST document handler. |
Add stylesheets to header
Name | Type | Description |
---|---|---|
$head |
DOMElement |
Escape all special characters in URIs
Name | Type | Description |
---|---|---|
$url |
string |
Generate footnote reference link
Generate an internal target name out of the footnote name, which may contain special characters, which are not allowed for URL anchors and are converted to alphanumeric strings by this method.
Name | Type | Description |
---|---|---|
$name |
string | |
$number |
string |
Docarate RST AST
Visit the RST abstract syntax tree.
Name | Type | Description |
---|---|---|
$ast |
ezcDocumentRstDocumentNode |
Method | Description |
---|---|
ezcDocumentRstVisitor::visit() |
Docarate RST AST |
Method | Description |
---|---|
ezcDocumentRstXhtmlBodyVisitor::visit() |
Docarate RST AST |
Visit anonomyous reference node
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit blockquotes
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit bullet lists
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit comment
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit definition list item
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit directive
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit enumerated lists
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit external reference node
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit field list item
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Method | Description |
---|---|
ezcDocumentRstXhtmlBodyVisitor::visitFieldListItem() |
Visit field list item |
Visit footnote
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit inline target node
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit internal reference node
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit interpreted text node markup
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit line block
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit line block line
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit single AST node
Visit a single AST node, may be called for each node found anywhere as child. The current position in the DOMDocument is passed by a reference to the current DOMNode, which is operated on.
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Visit section node
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |
Method | Description |
---|---|
ezcDocumentRstXhtmlBodyVisitor::visitSection() |
Visit section node |
Visit table cell
Name | Type | Description |
---|---|---|
$root |
DOMNode | |
$node |
ezcDocumentRstNode |