BlockStart
in package
FinalYes
Result object for starting parsing of a block; see static methods for constructors
Table of Contents
Properties
- $blockParsers : array<string|int, BlockContinueParserInterface>
- $cursorState : CursorState|null
- $isAborting : bool
- $replaceActiveBlockParser : bool
Methods
- at() : $this
- Signal that we want to parse at the given cursor position
- getBlockParsers() : array<string|int, BlockContinueParserInterface>
- getCursorState() : CursorState|null
- isReplaceActiveBlockParser() : bool
- none() : null
- Signal that we cannot parse whatever is here
- of() : self
- Signal that we'd like to register the given parser(s) so they can parse the current block
- replaceActiveBlockParser() : $this
- Signal that we want to replace the active block parser with this one
- __construct() : mixed
Properties
$blockParsers
private
array<string|int, BlockContinueParserInterface>
$blockParsers
Tags
$cursorState
private
CursorState|null
$cursorState
= null
Tags
$isAborting
private
bool
$isAborting
= false
$replaceActiveBlockParser
private
bool
$replaceActiveBlockParser
= false
Tags
Methods
at()
Signal that we want to parse at the given cursor position
public
at(Cursor $cursor) : $this
Parameters
- $cursor : Cursor
Return values
$thisgetBlockParsers()
public
getBlockParsers() : array<string|int, BlockContinueParserInterface>
Return values
array<string|int, BlockContinueParserInterface>getCursorState()
public
getCursorState() : CursorState|null
Return values
CursorState|nullisReplaceActiveBlockParser()
public
isReplaceActiveBlockParser() : bool
Return values
boolnone()
Signal that we cannot parse whatever is here
public
static none() : null
Return values
nullof()
Signal that we'd like to register the given parser(s) so they can parse the current block
public
static of(BlockContinueParserInterface ...$blockParsers) : self
Parameters
- $blockParsers : BlockContinueParserInterface
Return values
selfreplaceActiveBlockParser()
Signal that we want to replace the active block parser with this one
public
replaceActiveBlockParser() : $this
Return values
$this__construct()
private
__construct(BlockContinueParserInterface ...$blockParsers) : mixed
Parameters
- $blockParsers : BlockContinueParserInterface