PHP Class League\CommonMark\Context

Inheritance: implements League\CommonMark\ContextInterface
Mostra file Open project: colinodell/commonmark-php Class Usage Examples

Protected Properties

Property Type Description
$blockCloser UnmatchedBlockCloser
$blocksParsed boolean
$container League\CommonMark\Block\Element\AbstractBlock
$doc League\CommonMark\Block\Element\AbstractBlock
$environment Environment
$line string
$lineNumber integer
$referenceParser
$tip League\CommonMark\Block\Element\AbstractBlock | null

Public Methods

Method Description
__construct ( Document $document, Environment $environment )
addBlock ( AbstractBlock $block ) : AbstractBlock
getBlockCloser ( ) : UnmatchedBlockCloser Finalize and close any unmatched blocks
getBlocksParsed ( ) : boolean
getContainer ( ) : AbstractBlock
getDocument ( ) : Document
getLine ( ) : string
getLineNumber ( ) : integer
getReferenceParser ( ) : ReferenceParser
getTip ( ) : AbstractBlock | null
replaceContainerBlock ( AbstractBlock $replacement )
setBlocksParsed ( boolean $bool )
setContainer ( AbstractBlock $container )
setNextLine ( string $line )
setTip ( AbstractBlock $block = null )

Method Details

__construct() public method

public __construct ( Document $document, Environment $environment )
$document League\CommonMark\Block\Element\Document
$environment Environment

addBlock() public method

public addBlock ( AbstractBlock $block ) : AbstractBlock
$block League\CommonMark\Block\Element\AbstractBlock
return League\CommonMark\Block\Element\AbstractBlock

getBlockCloser() public method

Finalize and close any unmatched blocks
public getBlockCloser ( ) : UnmatchedBlockCloser
return UnmatchedBlockCloser

getBlocksParsed() public method

public getBlocksParsed ( ) : boolean
return boolean

getContainer() public method

public getContainer ( ) : AbstractBlock
return League\CommonMark\Block\Element\AbstractBlock

getDocument() public method

public getDocument ( ) : Document
return League\CommonMark\Block\Element\Document

getLine() public method

public getLine ( ) : string
return string

getLineNumber() public method

public getLineNumber ( ) : integer
return integer

getReferenceParser() public method

public getReferenceParser ( ) : ReferenceParser
return ReferenceParser

getTip() public method

public getTip ( ) : AbstractBlock | null
return League\CommonMark\Block\Element\AbstractBlock | null

replaceContainerBlock() public method

public replaceContainerBlock ( AbstractBlock $replacement )
$replacement League\CommonMark\Block\Element\AbstractBlock

setBlocksParsed() public method

public setBlocksParsed ( boolean $bool )
$bool boolean

setContainer() public method

public setContainer ( AbstractBlock $container )
$container League\CommonMark\Block\Element\AbstractBlock

setNextLine() public method

public setNextLine ( string $line )
$line string

setTip() public method

public setTip ( AbstractBlock $block = null )
$block League\CommonMark\Block\Element\AbstractBlock

Property Details

$blockCloser protected_oe property

protected UnmatchedBlockCloser,League\CommonMark $blockCloser
return UnmatchedBlockCloser

$blocksParsed protected_oe property

protected bool $blocksParsed
return boolean

$container protected_oe property

protected AbstractBlock,League\CommonMark\Block\Element $container
return League\CommonMark\Block\Element\AbstractBlock

$doc protected_oe property

protected AbstractBlock,League\CommonMark\Block\Element $doc
return League\CommonMark\Block\Element\AbstractBlock

$environment protected_oe property

protected Environment,League\CommonMark $environment
return Environment

$line protected_oe property

protected string $line
return string

$lineNumber protected_oe property

protected int $lineNumber
return integer

$referenceParser protected_oe property

protected $referenceParser

$tip protected_oe property

protected AbstractBlock,League\CommonMark\Block\Element|null $tip
return League\CommonMark\Block\Element\AbstractBlock | null