Path

ez components / documentation / api reference / 1.1.2 / template


eZ Components 1.1.2

Template: ezcTemplateParserException

[ Tutorial ] [ EBNF ] [ Functions ] [ Syntax ] [ Class tree ] [ Element index ] [ ChangeLog ] [ Credits ]

Class: ezcTemplateParserException

Exception for failed element parsers. [source]
The exception will display the exact location(s) where the error occured with some extra description of what went wrong.

Parents

Exception
   |
   --ezcTemplateParserException

Member Variables

public mixed $errorCursor
Cursor where the error occured.
public string $errorDetails
A more detailed error message which can for instance give hints to the end-user why it failed.
public string $errorMessage
The one-liner error message.
public ezcTemplateSource $source
The source code object which caused the error.
public mixed $startCursor
Cursor of the parsed line.

Inherited Member Variables

From Exception (Internal Class):
protected  $code
protected  $file
protected  $line
protected  $message
private  $string
private  $trace

Method Summary

public ezcTemplateParserException __construct( $source, $startCursor, $errorCursor, $errorMessage, [$errorDetails = ""], $elements, $parser )
Initialises the exception with the failing elements, parser, source code and error messages.
public string getErrorMessage( )
Generates the error message from member variables and returns it.

Inherited Methods

From Exception (Internal Class) :
public Exception constructor __construct ( $message, $code )
public void getCode ( )
public void getFile ( )
public void getLine ( )
public void getMessage ( )
public void getTrace ( )
public void getTraceAsString ( )
public void __clone ( )
public void __toString ( )

Methods

__construct

ezcTemplateParserException __construct( ezcTemplateSource $source, $startCursor, $errorCursor, string $errorMessage, [string $errorDetails = ""], array $elements, ezcTemplateSourceToTstParser $parser )
Initialises the exception with the failing elements, parser, source code and error messages.

Parameters

Name Type Description
$elements array An array of elements which contains the start and end cursor for the errors, needs at least one element entry.
$parser ezcTemplateSourceToTstParser The parser which was used when error occured, can be null.
$source ezcTemplateSource The source code which caused the error, used for file path.
$errorMessage string The error message.
$errorDetails string Extra details for error.
$startCursor ezcTemplateCursor  
$errorCursor ezcTemplateCursor  

Redefinition of

Method Description
Exception::constructor __construct ( $message, $code )  

getErrorMessage

string getErrorMessage( )
Generates the error message from member variables and returns it.

Last updated: Thu, 01 Nov 2007