1 | <?php |
||
10 | class RemoveWhitespace extends AbstractPass |
||
11 | { |
||
12 | /** |
||
13 | * @var bool Whether to remove blank lines from the source |
||
14 | */ |
||
15 | public $removeBlankLines = true; |
||
16 | |||
17 | /** |
||
18 | * @var bool Whether to remove the indentation at the start of a line |
||
19 | */ |
||
20 | public $removeIndentation = false; |
||
21 | |||
22 | /** |
||
23 | * @var bool Whether to remove superfluous whitespace inside of a line |
||
24 | */ |
||
25 | public $removeSameLineWhitespace = true; |
||
26 | |||
27 | /** |
||
28 | * {@inheritdoc} |
||
29 | */ |
||
30 | 13 | protected function optimizeStream() |
|
45 | |||
46 | /** |
||
47 | * Generate the regexp that corresponds to the removal options |
||
48 | * |
||
49 | * @return string |
||
50 | */ |
||
51 | 13 | protected function getRegexp() |
|
65 | } |