| 1 | <?php |
||
| 12 | class StructuredDataExtension extends AbstractExtension |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var StructuredDataAwarePage |
||
| 16 | */ |
||
| 17 | protected $page; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * @var string |
||
| 21 | */ |
||
| 22 | protected $encoding; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @param StructuredDataAwarePage $page |
||
| 26 | */ |
||
| 27 | public function __construct(StructuredDataAwarePage $page) |
||
| 31 | |||
| 32 | /** |
||
| 33 | * {@inheritdoc} |
||
| 34 | */ |
||
| 35 | public function getFunctions() |
||
| 41 | |||
| 42 | /** |
||
| 43 | * Creates a script tag with type 'json-ld' and the JSON-LD string stored in page object. |
||
| 44 | * |
||
| 45 | * @return string |
||
| 46 | */ |
||
| 47 | public function getStructuredData() |
||
| 55 | } |
||
| 56 |