public function Lexer::isNextTokenAny

Checks whether any of the given tokens matches the current lookahead

Parameters

array $tokens:

Return value

boolean

File

drupal/core/vendor/doctrine/common/lib/Doctrine/Common/Lexer.php, line 119

Class

Lexer
Base class for writing simple lexers, i.e. for creating small DSLs.

Namespace

Doctrine\Common

Code

public function isNextTokenAny(array $tokens) {
  return null !== $this->lookahead && in_array($this->lookahead['type'], $tokens, true);
}