private function getModifiersSequences(Tokens $tokens, $startIndex, $endIndex)
    {
        $sequence = [];
        for ($i = $startIndex; $i < $endIndex - 1; ++$i) {
            if ($tokens[$i]->isWhitespace() || $tokens[$i]->isComment()) {
                continue;
            }

            if (!$tokens[$i]->isGivenKind([T_PUBLIC, T_PROTECTED, T_PRIVATE, T_STATIC, T_CONST, T_VAR])) {
                break;
            }

            $sequence[] = clone $tokens[$i];
            $sequence[] = new Token([T_WHITESPACE, ' ']);
        }

        return $sequence;
    }
private function getModifiersSequences(Tokens $tokens, $startIndex, $endIndex)
    {
        $sequence = [];
        for ($i = $startIndex; $i < $endIndex - 1; ++$i) {
            if ($tokens[$i]->isWhitespace() || $tokens[$i]->isComment()) {
                continue;
            }

            if (!$tokens[$i]->isGivenKind([T_PUBLIC, T_PROTECTED, T_PRIVATE, T_STATIC, T_CONST, T_VAR])) {
                break;
            }

            $sequence[] = clone $tokens[$i];
            $sequence[] = new Token([T_WHITESPACE, ' ']);
        }

        return $sequence;
    }
private function getModifiersSequences ( Tokens $ tokens , $ startIndex , $ endIndex ) { $ sequence = [ ] ; for ( $ i = $ startIndex ; $ i < $ endIndex - 1 ; ++ $ i ) { if ( $ tokens [ $ i ] -> isWhitespace ( ) || $ tokens [ $ i ] -> isComment ( ) ) { continue ; } if ( ! $ tokens [ $ i ] -> isGivenKind ( [ T_PUBLIC , T_PROTECTED , T_PRIVATE , T_STATIC , T_CONST , T_VAR ] ) ) { break ; } $ sequence [ ] = clone $ tokens [ $ i ] ; $ sequence [ ] = new Token ( [ T_WHITESPACE , ' ' ] ) ; } return $ sequence ; }
@param Tokens $tokens
@param int    $startIndex
@param int    $endIndex

@return Token[]
@param Tokens $tokens @param int $startIndex @param int $endIndex