Esempio n. 1
0
 protected function addToken($source, $end)
 {
     $start = $end - mb_strlen($source);
     $token = HtmlToken::create($source);
     $token->offset = array($start, $end);
     $this->res[] = $token;
 }
Esempio n. 2
0
 public function wrap($code_before, $code_after)
 {
     $this->parent->addChildBefore(HtmlToken::create($code_before), $this);
     $this->parent->addChildAfter(HtmlToken::create($code_after), $this);
 }
Esempio n. 3
0
 protected function _bufferCharacter($char)
 {
     $this->_Token->ensureIsCharacterToken();
     $this->_Token->appendToCharacter($char);
 }