summaryrefslogtreecommitdiff
path: root/src/Renderer/EngineInterface.php
blob: dd713029d94556b59876a55c6cc5ef3e11529eda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php

namespace Engelsystem\Renderer;

interface EngineInterface
{
    /**
     * Render a template
     *
     * @param string  $path
     * @param mixed[] $data
     * @return string
     */
    public function get(string $path, array $data = []): string;

    /**
     * @param string $path
     * @return bool
     */
    public function canRender(string $path): bool;

    /**
     * @param string|mixed[] $key
     * @param mixed          $value
     */
    public function share($key, $value = null): void;
}