Documentation

HTML5_InputStream
in package

Table of Contents

$errors  : mixed
Parse errors.
$char  : mixed
The current integer byte position we are in $data
$data  : mixed
The string data we're parsing.
$EOF  : mixed
Length of $data; when $char === $data, we are at the end-of-file.
__construct()  : mixed
char()  : bool|string
Retrieve the currently consume character.
charsUntil()  : bool|string
Matches as far as possible until we reach a certain set of bytes and returns the matched substring.
charsWhile()  : bool|string
Matches as far as possible with a certain set of bytes and returns the matched substring.
getColumnOffset()  : int
Returns the current column of the current line that the tokenizer is at.
getCurrentLine()  : int
Returns the current line that the tokenizer is at.
remainingChars()  : string|bool
Get all characters until EOF.
unget()  : mixed
Unconsume one character.

Properties

$char

The current integer byte position we are in $data

private mixed $char

$data

The string data we're parsing.

private mixed $data

$EOF

Length of $data; when $char === $data, we are at the end-of-file.

private mixed $EOF

Methods

__construct()

public __construct( $data) : mixed
Parameters
$data :

| Data to parse

Tags
throws
Exception
Return values
mixed

char()

Retrieve the currently consume character.

public char() : bool|string
Tags
note

This performs bounds checking

Return values
bool|string

charsUntil()

Matches as far as possible until we reach a certain set of bytes and returns the matched substring.

public charsUntil( $bytes[, null $max = null ]) : bool|string
Parameters
$bytes :

| Bytes to match.

$max : null = null
Return values
bool|string

charsWhile()

Matches as far as possible with a certain set of bytes and returns the matched substring.

public charsWhile( $bytes[, null $max = null ]) : bool|string
Parameters
$bytes :

| Bytes to match.

$max : null = null
Return values
bool|string

getColumnOffset()

Returns the current column of the current line that the tokenizer is at.

public getColumnOffset() : int
Return values
int

getCurrentLine()

Returns the current line that the tokenizer is at.

public getCurrentLine() : int
Return values
int

remainingChars()

Get all characters until EOF.

public remainingChars() : string|bool
Tags
note

This performs bounds checking

Return values
string|bool

unget()

Unconsume one character.

public unget() : mixed
Return values
mixed

Search results