1 | <?php |
||
11 | * Class AlignmentTokenParser. |
||
12 | */ |
||
13 | class AlignmentTokenParser extends BaseTokenParser |
||
14 | { |
||
15 | /** |
||
16 | * @var string |
||
17 | */ |
||
18 | private $alignment; |
||
19 | |||
20 | /** |
||
21 | * AlignmentTokenParser constructor. |
||
22 | * |
||
23 | * @param array $attributes optional attributes for the corresponding node |
||
24 | * @param string $alignment |
||
25 | * |
||
26 | * @throws InvalidArgumentException |
||
27 | */ |
||
28 | public function __construct(array $attributes = [], string $alignment = HeaderFooterWrapper::ALIGNMENT_CENTER) |
||
34 | |||
35 | /** |
||
36 | * {@inheritdoc} |
||
37 | * |
||
38 | * @throws InvalidArgumentException |
||
39 | */ |
||
40 | public function createNode(array $nodes = [], int $lineNo = 0): Twig_Node |
||
44 | |||
45 | /** |
||
46 | * {@inheritdoc} |
||
47 | */ |
||
48 | public function getTag() |
||
49 | { |
||
50 | return 'xls'.$this->alignment; |
||
51 | } |
||
53 |