Completed
Push — master ( a3c2e5...7dfd4a )
by Tom
02:04
created
src/Builder.php 1 patch
Doc Comments   +8 added lines patch added patch discarded remove patch
@@ -62,6 +62,10 @@  discard block
 block discarded – undo
62 62
 		return (object) $result;
63 63
 	}
64 64
 
65
+	/**
66
+	 * @param Template $template
67
+	 * @param Config $config
68
+	 */
65 69
 	private function processRules($template, $config) {
66 70
 		$rules = $this->getRules($template, $config);
67 71
 
@@ -71,6 +75,10 @@  discard block
 block discarded – undo
71 75
 	}
72 76
 
73 77
 	//Add a postprocessing hook. This cleans up anything transphporm has added to the markup which needs to be removed
78
+
79
+	/**
80
+	 * @param Template $template
81
+	 */
74 82
 	private function doPostProcessing($template) {
75 83
 		$template->addHook('//*[@transphporm]', new Hook\PostProcess());
76 84
 		return $template;
Please login to merge, or discard this patch.
src/Formatter/HTMLFormatter.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -7,6 +7,9 @@
 block discarded – undo
7 7
         $this->templateFunction = $templateFunction;
8 8
     }
9 9
 
10
+    /**
11
+     * @param string $val
12
+     */
10 13
     public function html($val) {
11 14
 		return $this->templateFunction->run(['<template>' . $val . '</template>']);
12 15
 	}
Please login to merge, or discard this patch.
src/Parser/CssToXpath.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -13,6 +13,9 @@
 block discarded – undo
13 13
 	private $functionSet;
14 14
 	private $id;
15 15
 
16
+	/**
17
+	 * @param string $id
18
+	 */
16 19
 	public function __construct(\Transphporm\FunctionSet $functionSet, $prefix = '', $id = null) {
17 20
 		$this->id = $id;
18 21
 		self::$instances[$this->id] = $this;
Please login to merge, or discard this patch.
src/Parser/Sheet.php 1 patch
Doc Comments   +10 added lines patch added patch discarded remove patch
@@ -39,6 +39,9 @@  discard block
 block discarded – undo
39 39
 		return $this->cache->write($this->file, $rules, $this->import);
40 40
 	}
41 41
 
42
+	/**
43
+	 * @param integer $indexStart
44
+	 */
42 45
 	private function parseTokens($indexStart) {
43 46
 		$this->rules = [];
44 47
 		foreach (new TokenFilterIterator($this->tss, [Tokenizer::WHITESPACE]) as $token) {
@@ -65,6 +68,10 @@  discard block
 block discarded – undo
65 68
 		if (empty($rules) && count($this->tss) > 0) throw new \Exception('No TSS rules parsed');
66 69
 	}
67 70
 
71
+	/**
72
+	 * @param Tokens $selector
73
+	 * @param integer $index
74
+	 */
68 75
 	private function CssToRules($selector, $index, $properties, $line) {
69 76
 		$parts = $selector->trim()->splitOnToken(Tokenizer::ARG);
70 77
 		$rules = [];
@@ -88,6 +95,9 @@  discard block
 block discarded – undo
88 95
 		return $rules;
89 96
 	}
90 97
 
98
+	/**
99
+	 * @param integer $indexStart
100
+	 */
91 101
 	private function processingInstructions($token, $indexStart) {
92 102
 		if ($token['type'] !== Tokenizer::AT_SIGN) return false;
93 103
 		$tokens = $this->tss->from(Tokenizer::AT_SIGN, false)->to(Tokenizer::SEMI_COLON, false);
Please login to merge, or discard this patch.
src/Property/ContentPseudo/BeforeAfter.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -4,6 +4,9 @@
 block discarded – undo
4 4
 	private $insertLocation;
5 5
 	private $content;
6 6
 
7
+	/**
8
+	 * @param string $insertLocation
9
+	 */
7 10
 	public function __construct($insertLocation, \Transphporm\Property\Content $content) {
8 11
 		$this->insertLocation = $insertLocation;
9 12
 		$this->content = $content;
Please login to merge, or discard this patch.
src/Property/Content.php 1 patch
Doc Comments   +16 added lines patch added patch discarded remove patch
@@ -27,6 +27,9 @@  discard block
 block discarded – undo
27 27
 		}
28 28
 	}
29 29
 
30
+	/**
31
+	 * @param \DOMElement $element
32
+	 */
30 33
 	private function shouldRun($element) {
31 34
 		do {
32 35
 			if (in_array($element->getAttribute('transphporm'), ['includedtemplate', 'added']))  return false;
@@ -43,6 +46,10 @@  discard block
 block discarded – undo
43 46
 		$this->contentPseudo[$name] = $contentPseudo;
44 47
 	}
45 48
 
49
+	/**
50
+	 * @param \DOMElement $element
51
+	 * @param \Transphporm\Hook\PseudoMatcher $pseudoMatcher
52
+	 */
46 53
 	private function processPseudo($value, $element, $pseudoMatcher) {
47 54
 		foreach ($this->contentPseudo as $pseudoName => $pseudoFunction) {
48 55
 			if ($pseudoMatcher->hasFunction($pseudoName)) {
@@ -81,6 +88,9 @@  discard block
 block discarded – undo
81 88
 	}
82 89
 
83 90
 
91
+	/**
92
+	 * @param \DOMElement $element
93
+	 */
84 94
 	private function replaceContent($element, $content) {
85 95
 		//If this rule was cached, the elements that were added last time need to be removed prior to running the rule again.
86 96
 		if ($transphpormMode = $element->getAttribute('transphporm')) {
@@ -115,12 +125,18 @@  discard block
 block discarded – undo
115 125
 		}
116 126
 	}
117 127
 
128
+	/**
129
+	 * @param \DOMElement $element
130
+	 */
118 131
 	private function appendContent($element, $content) {
119 132
 		foreach ($this->getNode($content, $element->ownerDocument) as $node) {
120 133
 			$element->appendChild($node);
121 134
 		}
122 135
 	}
123 136
 
137
+	/**
138
+	 * @param \DOMElement $element
139
+	 */
124 140
 	private function removeAllChildren($element) {
125 141
 		while ($element->hasChildNodes()) $element->removeChild($element->firstChild);
126 142
 	}
Please login to merge, or discard this patch.