NaifyView\Executor\InheritanceRootRuntime クラス

InheritanceRootRuntime — 文書ルートの継承関係と上書きブロックを準備する

親テンプレートを描画する前に、子側の定義と実行状態を引き継げる形にまとめる。

ASTを直接実行する経路の内部部品。通常の描画にはView::render()を使う。

プロパティ

名前型説明
private $templateLoader TemplateLoader template load / resolve owner
private $macroRuntime MacroRuntime root macro registry owner
private $templateRecursionRuntime TemplateRecursionRuntime extends recursion guard

メソッド

メソッド説明
public __construct(TemplateLoader $templateLoader, MacroRuntime $macroRuntime, TemplateRecursionRuntime $templateRecursionRuntime): void インスタンスを初期化する
public renderDocument(DocumentNode $document, array $scope, array $state, callable $renderNodes): NodeRenderResult `renderDocument()` を実行する
private prepareTemplateRoot(DocumentNode $document, array $state): array `prepareTemplateRoot()` を実行する
private mergeBlockOverrides(array $currentBlocks, array $existingOverrides): array `mergeBlockOverrides()` を実行する
private pushTemplateTrace(array $state): array `pushTemplateTrace()` を実行する
private normalizeTracePath(string $path): string `normalizeTracePath()` を実行する
private readBlockOverrides(array $state): array `readBlockOverrides()` を実行する
private readMacroRegistry(array $state): array `readMacroRegistry()` を実行する