本文整理匯總了PHP中ezcTemplateSourceToTstParser類的典型用法代碼示例。如果您正苦於以下問題:PHP ezcTemplateSourceToTstParser類的具體用法?PHP ezcTemplateSourceToTstParser怎麽用?PHP ezcTemplateSourceToTstParser使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了ezcTemplateSourceToTstParser類的9個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1:
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, $parentParser, $startCursor)
{
parent::__construct($parser, $parentParser, $startCursor);
$this->startBracket = '{';
$this->endBracket = '}';
$this->block = null;
}
示例2:
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, $parentParser, $startCursor)
{
parent::__construct($parser, $parentParser, $startCursor);
$this->currentOperator = null;
$this->rootOperator = null;
$this->minPrecedence = false;
}
示例3:
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, $parentParser, $startCursor)
{
parent::__construct($parser, $parentParser, $startCursor);
$this->block = null;
}
示例4:
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, $parentParser, $startCursor)
{
parent::__construct($parser, $parentParser, $startCursor);
$this->variable = null;
$this->variableName = null;
}
示例5:
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, $parentParser, $startCursor)
{
parent::__construct($parser, $parentParser, $startCursor);
}
示例6: parseRequiredType
/**
* Parses a required type.
*
* @param mixed $type
* @param ezcTemplateCursor $startCursor
* @param bool $mergeElements
* @return bool
*/
protected function parseRequiredType($type, ezcTemplateCursor $startCursor = null, $mergeElements = true)
{
if (is_string($type)) {
$className = 'ezcTemplate' . $type . 'SourceToTstParser';
if (!ezcBaseFeatures::classExists($className)) {
throw new ezcTemplateInternalException("Could instantiate sub-parser for type <{$type}>, the class <{$className}> does not exist");
}
$this->subParser = new $className($this->parser, $this, $startCursor);
} else {
if (is_object($type) && $type instanceof ezcTemplateSourceToTstParser) {
$this->subParser = $type;
} else {
throw new ezcTemplateInternalException("Cannot use <" . gettype($type) . "> as parser in ezcTemplateSourceToTstParser::parseRequiredType()");
}
}
$this->lastParser = $this->subParser;
$this->subParser->parse();
if ($this->subParser->status == self::PARSE_SUCCESS) {
$this->currentCursor->copy($this->subParser->endCursor);
$this->lastCursor->copy($this->currentCursor);
if ($mergeElements) {
$this->mergeElements($this->subParser);
}
$this->subParser = null;
return true;
} elseif ($this->subParser->status === self::PARSE_PARTIAL_SUCCESS) {
$this->status = $this->subParser->status;
return false;
}
return false;
}
示例7:
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, $parentParser, $startCursor)
{
parent::__construct($parser, $parentParser, $startCursor);
$this->value = null;
$this->element = null;
}
示例8:
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, $parentParser, $startCursor)
{
parent::__construct($parser, $parentParser, $startCursor);
$this->readingParameter = false;
}
示例9: __construct
/**
* Passes control to parent.
*
* @param ezcTemplateParser $parser
* @param ezcTemplateSourceToTstParser $parentParser
* @param ezcTemplateCursor $startCursor
*/
function __construct(ezcTemplateParser $parser, ezcTemplateSourceToTstParser $parentParser, ezcTemplateCursor $startCursor = null)
{
parent::__construct($parser, $parentParser, $startCursor);
$this->block = null;
}