/** * Parses the given token reader * * @param \vc\Data\File $file The file to parse data into * @param \vc\Tokens\Access $access The token access * @return NULL */ public function parse(\vc\Data\File $file, \vc\Tokens\Access $access) { while ($access->hasToken()) { $nspace = new \vc\Data\NSpace(); // If we can't find a namespace, then we are in the global scope if ($this->findNS($access)) { $inner = $this->buildNS($nspace, $access); } else { $inner = $access->untilTokens(array(Token::T_NAMESPACE)); } $file->addNamespace($nspace); $this->nspace->parseNSpace($nspace, $inner); } }