Parsoid
A bidirectional parser between wikitext and HTML5
Loading...
Searching...
No Matches
Wikimedia\Parsoid\Wt2Html\TT\NoInclude Class Reference

Simple noinclude implementation. More...

+ Inheritance diagram for Wikimedia\Parsoid\Wt2Html\TT\NoInclude:
+ Collaboration diagram for Wikimedia\Parsoid\Wt2Html\TT\NoInclude:

Public Member Functions

 __construct (TokenTransformManager $manager, array $options)
 
- Public Member Functions inherited from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector
 onTag (Token $token)
 This handler is called for tokens that are not EOFTk or NLTk tokens.The handler may choose to process only specific kinds of tokens. For example, a list handler may only process 'listitem' TagTk tokens.
Parameters
Token$tokenToken to be processed
Returns
TokenHandlerResult|null A TokenHandlerResult, or null to efficiently indicate that the input token is unchanged.

 
 onEnd (EOFTk $token)
 This handler is called for EOF tokens only.
Parameters
EOFTk$tokenEOF token to be processed
Returns
TokenHandlerResult|null A TokenHandlerResult, or null to efficiently indicate that the input token is unchanged.

 
 onAny ( $token)
 This handler is called for all tokens in the token stream except if (a) The more specific handlers above modified the token (b) the more specific handlers (onTag, onEnd, onNewline) have set the skip flag in their return values.(c) this handlers 'active' flag is set to false (can be set by any of the handlers).
Parameters
Token | string$tokenToken to be processed
Returns
TokenHandlerResult|null A TokenHandlerResult, or null to efficiently indicate that the input token is unchanged.

 
- Public Member Functions inherited from Wikimedia\Parsoid\Wt2Html\TT\TokenHandler
 setPipelineId (int $id)
 
 resetState (array $options)
 Resets any internal state for this token handler.
 
 isDisabled ()
 Is this transformer disabled?
 
 onNewline (NlTk $token)
 This handler is called for newline tokens only.
 
 process ( $tokens)
 Push an input array of tokens through the transformer and return the transformed tokens.
 

Protected Member Functions

 type ()
 
 name ()
 
 toEnd ()
 
 ackEnd ()
 
 transformation (array $collection)
 

Additional Inherited Members

- Static Public Member Functions inherited from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector
static buildMetaToken (TokenTransformManager $manager, string $tokenName, bool $isEnd, SourceRange $tsr, ?string $src)
 This helper function will build a meta token in the right way for these tags.
 
- Static Protected Member Functions inherited from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector
static buildStrippedMetaToken (TokenTransformManager $manager, string $tokenName, Token $startDelim, ?Token $endDelim)
 
- Protected Attributes inherited from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector
 $scopeStack
 
- Protected Attributes inherited from Wikimedia\Parsoid\Wt2Html\TT\TokenHandler
 $env
 
 $manager
 
 $pipelineId
 
 $options
 
 $disabled
 
 $onAnyEnabled
 
 $atTopLevel = false
 

Detailed Description

Simple noinclude implementation.

Strips all tokens in noinclude sections.

Constructor & Destructor Documentation

◆ __construct()

Wikimedia\Parsoid\Wt2Html\TT\NoInclude::__construct ( TokenTransformManager $manager,
array $options )
Parameters
TokenTransformManager$managermanager environment
array$optionsoptions

Reimplemented from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector.

Member Function Documentation

◆ ackEnd()

Wikimedia\Parsoid\Wt2Html\TT\NoInclude::ackEnd ( )
protected
Returns
bool

Reimplemented from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector.

◆ name()

Wikimedia\Parsoid\Wt2Html\TT\NoInclude::name ( )
protected
Returns
string

Reimplemented from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector.

◆ toEnd()

Wikimedia\Parsoid\Wt2Html\TT\NoInclude::toEnd ( )
protected
Returns
bool

Reimplemented from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector.

◆ transformation()

Wikimedia\Parsoid\Wt2Html\TT\NoInclude::transformation ( array $collection)
protected
Parameters
array$collection
Returns
TokenHandlerResult

Reimplemented from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector.

◆ type()

Wikimedia\Parsoid\Wt2Html\TT\NoInclude::type ( )
protected
Returns
string

Reimplemented from Wikimedia\Parsoid\Wt2Html\TT\TokenCollector.


The documentation for this class was generated from the following file: