Path

ez components / documentation / api reference / latest / document


eZ Components latest

Document: ezcDocumentParser

[ Tutorial ] [ Conversion ] [ Styles ] [ Class tree ] [ Element index ] [ ChangeLog ] [ Credits ]

Class: ezcDocumentParser

A base class for document parsers [source]

Implemented Interfaces

Descendents

Child Class Description
ezcDocumentRstParser Parser for RST documents
ezcDocumentWikiParser Parser for wiki documents.

Member Variables

protected ezcDocumentParserOptions $options
XML document base options.
protected array $properties = array(
'errors' => array(),)

Additional parser properties.

Method Summary

public ezcDocumentParser __construct( [$options = null] )
Construct new document
public array getErrors( )
Return list of errors occured during visiting the document.
public void triggerError( $level, $message, [$file = null], [$line = null], [$position = null] )
Trigger parser error

Methods

__construct

ezcDocumentParser __construct( [ezcDocumentParserOptions $options = null] )
Construct new document

Parameters

Name Type Description
$options ezcDocumentParserOptions  

Redefined in descendants as

Method Description
ezcDocumentRstParser::__construct() Construct new document

getErrors

array getErrors( )
Return list of errors occured during visiting the document.
May be an empty array, if on errors occured, or a list of ezcDocumentVisitException objects.

triggerError

void triggerError( int $level, string $message, [string $file = null], [int $line = null], [int $position = null] )
Trigger parser error
Emit a parser error and handle it dependiing on the current error reporting settings.

Parameters

Name Type Description
$level int  
$message string  
$file string  
$line int  
$position int  

Last updated: Mon, 21 Dec 2009