private function processInterface()
{
$current = $this->id;
$interfaceId = $this->addAtom('Interface');
$this->toggleContext(self::CONTEXT_INTERFACE);
$nameId = $this->processNextAsIdentifier();
$this->addLink($interfaceId, $nameId, 'NAME');
// Process extends
$rank = 0;
$fullcode = array();
$extends = $this->id + 1;
if ($this->tokens[$this->id + 1][0] === T_EXTENDS) {
do {
++$this->id;
// Skip extends or ,
$extendsId = $this->processOneNsname();
$this->setAtom($extendsId, array('rank' => $rank));
$this->addLink($interfaceId, $extendsId, 'EXTENDS');
$fullcode[] = $this->atoms[$extendsId]['fullcode'];
$this->addCall('class', $this->getFullnspath($extendsId), $extendsId);
} while ($this->tokens[$this->id + 1][0] === T_COMMA);
}
// Process block
++$this->id;
$blockId = $this->processBlock(false);
$this->popExpression();
$this->addLink($interfaceId, $blockId, 'BLOCK');
$fullnspath = $this->getFullnspath($nameId);
$this->setAtom($interfaceId, array('code' => $this->tokens[$current][1], 'fullcode' => $this->tokens[$current][1] . ' ' . $this->atoms[$nameId]['fullcode'] . (isset($extendsId) ? ' ' . $this->tokens[$extends][1] . ' ' . implode(', ', $fullcode) : '') . static::FULLCODE_BLOCK, 'line' => $this->tokens[$current][2], 'token' => $this->getToken($this->tokens[$current][0]), 'fullnspath' => $fullnspath));
$this->addDefinition('class', $fullnspath, $interfaceId);
$this->pushExpression($interfaceId);
$this->processSemicolon();
$this->toggleContext(self::CONTEXT_INTERFACE);
return $interfaceId;
}