You are here

public function Twig_TokenStream::__construct in Translation template extractor 6.3

Same name and namespace in other branches
  1. 7.3 vendor/Twig/TokenStream.php \Twig_TokenStream::__construct()
  2. 7.2 vendor/Twig/TokenStream.php \Twig_TokenStream::__construct()

Constructor.

Parameters

array $tokens An array of tokens:

string $filename The name of the filename which tokens are associated with:

File

vendor/Twig/TokenStream.php, line 30

Class

Twig_TokenStream
Represents a token stream.

Code

public function __construct(array $tokens, $filename = null) {
  $this->tokens = $tokens;
  $this->current = 0;
  $this->filename = $filename;
}