| 1 | <?php |
||
| 15 | class Output |
||
| 16 | { |
||
| 17 | use ExtendedArrayTrait; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * @var Node |
||
| 21 | */ |
||
| 22 | private $node; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @var int |
||
| 26 | */ |
||
| 27 | private $depth = 0; |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @var int |
||
| 31 | */ |
||
| 32 | private static $initialDepth = 0; |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Output constructor. |
||
| 36 | * |
||
| 37 | * @param Node $node |
||
| 38 | * @param int $depth |
||
| 39 | */ |
||
| 40 | 4 | public function __construct(Node $node, $depth = null) |
|
| 45 | |||
| 46 | /** |
||
| 47 | * @param int $depth |
||
| 48 | */ |
||
| 49 | 3 | public static function setDepth($depth) |
|
| 53 | |||
| 54 | /** |
||
| 55 | * @return string |
||
| 56 | */ |
||
| 57 | 3 | public function get() |
|
| 64 | |||
| 65 | /** |
||
| 66 | * |
||
| 67 | */ |
||
| 68 | 1 | public function render() |
|
| 72 | |||
| 73 | /** |
||
| 74 | * @param int $tabSize |
||
| 75 | */ |
||
| 76 | 1 | public static function setTabSize($tabSize) |
|
| 80 | |||
| 81 | /** |
||
| 82 | * @param string $string |
||
| 83 | * @return null|string |
||
| 84 | */ |
||
| 85 | 3 | private function attributes($string = ' ') |
|
| 91 | } |
||
| 92 |