@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | private $rules; |
11 | 11 | private $configLine; |
12 | 12 | private $file; |
13 | - private $filePath; |
|
13 | + private $filePath; |
|
14 | 14 | private $line; |
15 | 15 | private $valueParser; |
16 | 16 | private $pseudoMatcher; |
@@ -18,11 +18,11 @@ discard block |
||
18 | 18 | private $functionSet; |
19 | 19 | |
20 | 20 | public function __construct(array $rules, &$configLine, $file, $line, PseudoMatcher $pseudoMatcher, |
21 | - \Transphporm\Parser\Value $valueParser, \Transphporm\FunctionSet $functionSet, \Transphporm\FilePath $filePath) { |
|
21 | + \Transphporm\Parser\Value $valueParser, \Transphporm\FunctionSet $functionSet, \Transphporm\FilePath $filePath) { |
|
22 | 22 | $this->rules = $rules; |
23 | 23 | $this->configLine = &$configLine; |
24 | 24 | $this->file = $file; |
25 | - $this->filePath = $filePath; |
|
25 | + $this->filePath = $filePath; |
|
26 | 26 | $this->line = $line; |
27 | 27 | $this->valueParser = $valueParser; |
28 | 28 | $this->pseudoMatcher = $pseudoMatcher; |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | } |
31 | 31 | |
32 | 32 | public function run(\DomElement $element) { |
33 | - if ($this->file !== null) $this->filePath->setBaseDir(dirname(realpath($this->file)) . DIRECTORY_SEPARATOR); |
|
33 | + if ($this->file !== null) $this->filePath->setBaseDir(dirname(realpath($this->file)) . DIRECTORY_SEPARATOR); |
|
34 | 34 | $this->functionSet->setElement($element); |
35 | 35 | $this->configLine = $this->line; |
36 | 36 | try { |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | |
21 | 21 | $this->translators = [ |
22 | 22 | Tokenizer::WHITESPACE => function($string) use ($prefix) { return '//' . $prefix . $string; }, |
23 | - Tokenizer::MULTIPLY => function () { return '*'; }, |
|
23 | + Tokenizer::MULTIPLY => function () { return '*'; }, |
|
24 | 24 | '' => function($string) use ($prefix) { return '/' . $prefix . $string; }, |
25 | 25 | Tokenizer::GREATER_THAN => function($string) use ($prefix) { return '/' . $prefix . $string; }, |
26 | 26 | Tokenizer::NUM_SIGN => function($string) { return '[@id=\'' . $string . '\']'; }, |
@@ -44,11 +44,11 @@ discard block |
||
44 | 44 | $functionSet->setElement($element[0]); |
45 | 45 | |
46 | 46 | $attributes = array(); |
47 | - foreach($element[0]->attributes as $attribute_name => $attribute_node) { |
|
48 | - $attributes[$attribute_name] = $attribute_node->nodeValue; |
|
49 | - } |
|
47 | + foreach($element[0]->attributes as $attribute_name => $attribute_node) { |
|
48 | + $attributes[$attribute_name] = $attribute_node->nodeValue; |
|
49 | + } |
|
50 | 50 | |
51 | - $parser = new \Transphporm\Parser\Value($functionSet, true); |
|
51 | + $parser = new \Transphporm\Parser\Value($functionSet, true); |
|
52 | 52 | $return = $parser->parseTokens($attr, $attributes); |
53 | 53 | |
54 | 54 | return $return[0] === '' ? false : $return[0]; |