class Token
Same name in this branch
- 11.1.x vendor/theseer/tokenizer/src/Token.php \TheSeer\Tokenizer\Token
- 11.1.x vendor/doctrine/lexer/src/Token.php \Doctrine\Common\Lexer\Token
- 11.1.x vendor/twig/twig/src/Token.php \Twig\Token
- 11.1.x vendor/symfony/css-selector/Parser/Token.php \Symfony\Component\CssSelector\Parser\Token
- 11.1.x vendor/mck89/peast/lib/Peast/Syntax/Token.php \Peast\Syntax\Token
- 11.1.x core/lib/Drupal/Core/Render/Element/Token.php \Drupal\Core\Render\Element\Token
- 11.1.x core/lib/Drupal/Core/Utility/Token.php \Drupal\Core\Utility\Token
A PHP token. On PHP 8.0 this extends from PhpToken.
Hierarchy
- class \PhpParser\Token extends \Internal\TokenPolyfill
Expanded class hierarchy of Token
9 files declare their use of Token
- AsymmetricVisibilityTokenEmulator.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ Lexer/ TokenEmulator/ AsymmetricVisibilityTokenEmulator.php - AttributeEmulator.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ Lexer/ TokenEmulator/ AttributeEmulator.php - CommentAnnotatingVisitor.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ NodeVisitor/ CommentAnnotatingVisitor.php - Emulative.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ Lexer/ Emulative.php - ExplicitOctalEmulator.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ Lexer/ TokenEmulator/ ExplicitOctalEmulator.php
15 string references to 'Token'
- AbstractPatternSniff::createTokenPattern in vendor/
squizlabs/ php_codesniffer/ src/ Sniffs/ AbstractPatternSniff.php - Creates a token pattern.
- AbstractPatternSniff::getPatternTokenTypes in vendor/
squizlabs/ php_codesniffer/ src/ Sniffs/ AbstractPatternSniff.php - Returns the token types that the specified pattern is checking for.
- AbstractPatternSniff::processPattern in vendor/
squizlabs/ php_codesniffer/ src/ Sniffs/ AbstractPatternSniff.php - Processes the pattern and verifies the code at $stackPtr.
- BatchStorage::schemaDefinition in core/
lib/ Drupal/ Core/ Batch/ BatchStorage.php - Defines the schema for the batch table.
- ContentTranslationHandler::entityFormSharedElements in core/
modules/ content_translation/ src/ ContentTranslationHandler.php - Process callback: determines which elements get clue in the form.
File
-
vendor/
nikic/ php-parser/ lib/ PhpParser/ Token.php, line 8
Namespace
PhpParserView source
class Token extends Internal\TokenPolyfill {
/** Get (exclusive) zero-based end position of the token. */
public function getEndPos() : int {
return $this->pos + \strlen($this->text);
}
/** Get 1-based end line number of the token. */
public function getEndLine() : int {
return $this->line + \substr_count($this->text, "\n");
}
}
Members
Title Sort descending | Modifiers | Object type | Summary |
---|---|---|---|
Token::getEndLine | public | function | Get 1-based end line number of the token. |
Token::getEndPos | public | function | Get (exclusive) zero-based end position of the token. |