|
@@ 108-110 (lines=3) @@
|
| 105 |
|
*/ |
| 106 |
|
protected function save($dsl, $context) |
| 107 |
|
{ |
| 108 |
|
if (!isset($dsl['file']) || (!isset($dsl['body']) && !isset($dsl['template']))) { |
| 109 |
|
throw new \Exception("Can not save file: name or body or template missing"); |
| 110 |
|
} |
| 111 |
|
|
| 112 |
|
if (is_string($dsl['body'])) { |
| 113 |
|
$contents = $this->resolveReferencesInText($dsl['body']); |
|
@@ 148-150 (lines=3) @@
|
| 145 |
|
*/ |
| 146 |
|
protected function append($dsl, $context) |
| 147 |
|
{ |
| 148 |
|
if (!isset($dsl['file']) || (!isset($dsl['body']) && !isset($dsl['template']))) { |
| 149 |
|
throw new \Exception("Can not append to file: name or body or template missing"); |
| 150 |
|
} |
| 151 |
|
|
| 152 |
|
if (is_string($dsl['body'])) { |
| 153 |
|
$contents = $this->resolveReferencesInText($dsl['body']); |
|
@@ 183-185 (lines=3) @@
|
| 180 |
|
*/ |
| 181 |
|
protected function prepend($dsl, $context) |
| 182 |
|
{ |
| 183 |
|
if (!isset($dsl['file']) || (!isset($dsl['body']) && !isset($dsl['template']))) { |
| 184 |
|
throw new \Exception("Can not prepend to file: name or body or template missing"); |
| 185 |
|
} |
| 186 |
|
|
| 187 |
|
if (is_string($dsl['body'])) { |
| 188 |
|
$contents = $this->resolveReferencesInText($dsl['body']); |