ParseError
extends RuntimeException
in package
implements
HasOffset, HasCategory
FinalYes
Table of Contents
Interfaces
- HasOffset
- Implemented by any exception that can report a byte/character offset into the source it failed on (lexer/parser errors) -- lets {@see DXNError::wrap()} preserve that offset without needing to know about every concrete exception class in the text/binary pipelines.
- HasCategory
- Implemented by any exception that knows its DXN.md §5 category -- `syntax`, `binary`, `encode/unsupported`, ... -- so {@see DXNError::wrap()} can carry it across without knowing every concrete exception class, the way {@see HasOffset} carries an offset.
Properties
- $codepointOffset : int|null
Methods
- __construct() : mixed
- category() : string
- DXN.md §5's category for text that does not parse.
- offset() : int|null
Properties
$codepointOffset read-only
private
int|null
$codepointOffset
Methods
__construct()
public
__construct(string $message[, int|null $codepointOffset = null ]) : mixed
Parameters
- $message : string
- $codepointOffset : int|null = null
category()
DXN.md §5's category for text that does not parse.
public
category() : string
Return values
stringoffset()
public
offset() : int|null