fix: Определения типов
This commit is contained in:
parent
9f6fd74b17
commit
dd74a97894
28 changed files with 334 additions and 249 deletions
|
|
@ -41,7 +41,8 @@ class Tales_Assets implements PHPTAL_Tales
|
|||
}
|
||||
|
||||
class Tales {
|
||||
static $site/*: SiteInterface*/;
|
||||
/** @var SiteInterface */
|
||||
static $site;
|
||||
|
||||
static function phptal_date ($e) {
|
||||
return date("d.m.Y", $e);
|
||||
|
|
@ -61,12 +62,11 @@ class Tales {
|
|||
*/
|
||||
static function phptal_component($expression) {
|
||||
$begin = floatval(microtime(true));
|
||||
$component/*: Component*/ = null;
|
||||
|
||||
/** @var Component */
|
||||
$component = self::$site->loadComponent($expression);
|
||||
$req = new HttpRequest();
|
||||
$req = new HttpRequest();
|
||||
$result = $component->execute($req);
|
||||
|
||||
|
||||
echo "<!-- ", $expression, ", ", round(floatval(microtime(true)) - $begin, 4), "sec -->";
|
||||
return $result;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue