PHP Класс SlevomatCodingStandard\Helpers\TokenHelper

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$ineffectiveTokenCodes
$nameTokenCodes
$typeKeywordTokenCodes

Открытые методы

Метод Описание
findFirstTokenOnNextLine ( PHP_CodeSniffer_File $phpcsFile, integer $pointer ) : integer | null
findNextAnyToken ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : integer | null
findNextEffective ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : integer | null
findNextExcluding ( PHP_CodeSniffer_File $phpcsFile, integer | integer[] $types, integer $startPointer, integer | null $endPointer = null ) : integer | null
findPreviousEffective ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : integer | null
findPreviousExcluding ( PHP_CodeSniffer_File $phpcsFile, integer[] | integer $types, integer $startPointer, integer | null $endPointer = null ) : integer | null
getContent ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : string
getLastTokenPointer ( PHP_CodeSniffer_File $phpcsFile ) : integer

Описание методов

findFirstTokenOnNextLine() публичный статический Метод

public static findFirstTokenOnNextLine ( PHP_CodeSniffer_File $phpcsFile, integer $pointer ) : integer | null
$phpcsFile PHP_CodeSniffer_File
$pointer integer search starts at this token, inclusive
Результат integer | null

findNextAnyToken() публичный статический Метод

public static findNextAnyToken ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : integer | null
$phpcsFile PHP_CodeSniffer_File
$startPointer integer search starts at this token, inclusive
$endPointer integer | null search ends at this token, exclusive
Результат integer | null

findNextEffective() публичный статический Метод

public static findNextEffective ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : integer | null
$phpcsFile PHP_CodeSniffer_File
$startPointer integer search starts at this token, inclusive
$endPointer integer | null search ends at this token, exclusive
Результат integer | null

findNextExcluding() публичный статический Метод

public static findNextExcluding ( PHP_CodeSniffer_File $phpcsFile, integer | integer[] $types, integer $startPointer, integer | null $endPointer = null ) : integer | null
$phpcsFile PHP_CodeSniffer_File
$types integer | integer[]
$startPointer integer search starts at this token, inclusive
$endPointer integer | null search ends at this token, exclusive
Результат integer | null

findPreviousEffective() публичный статический Метод

public static findPreviousEffective ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : integer | null
$phpcsFile PHP_CodeSniffer_File
$startPointer integer search starts at this token, inclusive
$endPointer integer | null search ends at this token, exclusive
Результат integer | null

findPreviousExcluding() публичный статический Метод

public static findPreviousExcluding ( PHP_CodeSniffer_File $phpcsFile, integer[] | integer $types, integer $startPointer, integer | null $endPointer = null ) : integer | null
$phpcsFile PHP_CodeSniffer_File
$types integer[] | integer
$startPointer integer search starts at this token, inclusive
$endPointer integer | null search ends at this token, exclusive
Результат integer | null

getContent() публичный статический Метод

public static getContent ( PHP_CodeSniffer_File $phpcsFile, integer $startPointer, integer | null $endPointer = null ) : string
$phpcsFile PHP_CodeSniffer_File
$startPointer integer search starts at this token, inclusive
$endPointer integer | null search ends at this token, exclusive
Результат string

getLastTokenPointer() публичный статический Метод

public static getLastTokenPointer ( PHP_CodeSniffer_File $phpcsFile ) : integer
$phpcsFile PHP_CodeSniffer_File
Результат integer

Описание свойств

$ineffectiveTokenCodes публичное статическое свойство

public static $ineffectiveTokenCodes

$nameTokenCodes публичное статическое свойство

public static $nameTokenCodes

$typeKeywordTokenCodes публичное статическое свойство

public static $typeKeywordTokenCodes