Conditions | 4 |
Paths | 3 |
Total Lines | 15 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 2 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
36 | public function toSyntax() |
||
37 | { |
||
38 | $doc = ''; |
||
39 | |||
40 | foreach ($this->listItemNodes as $li) { |
||
41 | $liText = str_repeat(' ', $this->depth); |
||
42 | $liText .= $this->prefix; |
||
43 | $lines = $li->toSyntax(); |
||
44 | if (!empty($lines) && $lines[0] !== ' ') { |
||
45 | $liText .= ' '; |
||
46 | } |
||
47 | $liText .= $lines . "\n"; |
||
48 | $doc .= $liText; |
||
49 | } |
||
50 | return rtrim($doc); // blocks should __not__ end with a newline, parents must handle breaks between children |
||
51 | } |
||
58 |