Completed
Push — master ( cf02ee...931a03 )
by SuRaMoN
02:56
created
src/itertools/CallbackRecursiveIterator.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,6 @@
 block discarded – undo
3 3
 namespace itertools;
4 4
 
5 5
 use RecursiveIterator;
6
-use IteratorIterator;
7 6
 use EmptyIterator;
8 7
 
9 8
 
Please login to merge, or discard this patch.
src/itertools/ComposingIterator.php 1 patch
Doc Comments   +9 added lines patch added patch discarded remove patch
@@ -71,6 +71,9 @@  discard block
 block discarded – undo
71 71
 		return iterator_count($this);
72 72
 	}
73 73
 
74
+	/**
75
+	 * @param \Closure $callback
76
+	 */
74 77
 	public function filter($callback)
75 78
 	{
76 79
 		return $this->callbackFilter($callback);
@@ -96,6 +99,9 @@  discard block
 block discarded – undo
96 99
 		}
97 100
 	}
98 101
 
102
+	/**
103
+	 * @param string $name
104
+	 */
99 105
 	protected function pushIteratorByClassName($name, $arguments)
100 106
 	{
101 107
 		$reflector = new ReflectionClass($name);
@@ -117,6 +123,9 @@  discard block
 block discarded – undo
117 123
 		return $this->setInnerIterator(new ZipIterator(array_merge(array($this->getInnerIterator()), $iterables)));
118 124
 	}
119 125
 
126
+	/**
127
+	 * @param string $template
128
+	 */
120 129
 	public function fixedLengthFormattedStringFromTemplate($template, array $nameMap = array(), array $options = array())
121 130
 	{
122 131
 		return $this->setInnerIterator(FixedLengthFormattedStringIterator::newFromTemplate($this->getInnerIterator(), $template, $nameMap, $options));
Please login to merge, or discard this patch.
src/itertools/FlippingIterator.php 2 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -10,6 +10,9 @@
 block discarded – undo
10 10
 
11 11
 class FlippingIterator extends IteratorIterator
12 12
 {
13
+	/**
14
+	 * @param integer[] $iterator
15
+	 */
13 16
 	public function __construct($iterator)
14 17
 	{
15 18
 		parent::__construct(IterUtil::asTraversable($iterator));
Please login to merge, or discard this patch.
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -2,10 +2,7 @@
 block discarded – undo
2 2
 
3 3
 namespace itertools;
4 4
 
5
-use InvalidArgumentException;
6 5
 use IteratorIterator;
7
-use Traversable;
8
-use ArrayIterator;
9 6
 
10 7
 
11 8
 class FlippingIterator extends IteratorIterator
Please login to merge, or discard this patch.
src/itertools/HistoryIterator.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -79,6 +79,9 @@
 block discarded – undo
79 79
 		$this->keepLastEntries($this->maxHistorySize + 1);
80 80
 	}
81 81
 
82
+	/**
83
+	 * @param integer $count
84
+	 */
82 85
 	protected function keepLastEntries($count)
83 86
 	{
84 87
 		while($this->history->count() > $count) {
Please login to merge, or discard this patch.
src/itertools/IterUtil.php 2 patches
Doc Comments   +14 added lines patch added patch discarded remove patch
@@ -120,6 +120,10 @@  discard block
 block discarded – undo
120 120
 		return true;
121 121
 	}
122 122
 
123
+	/**
124
+	 * @param \SplObjectStorage[] $iterable
125
+	 * @param string $method
126
+	 */
123 127
 	public static function invoke($iterable, $method)
124 128
 	{
125 129
 		return new MapIterator($iterable, function($element) use ($method) {
@@ -127,6 +131,9 @@  discard block
 block discarded – undo
127 131
 		});
128 132
 	}
129 133
 
134
+	/**
135
+	 * @param integer[] $iterable
136
+	 */
130 137
 	public static function sum($iterable, $initialValue = 0)
131 138
 	{
132 139
 		self::assertIsCollection($iterable);
@@ -137,6 +144,10 @@  discard block
 block discarded – undo
137 144
 		return $sum;
138 145
 	}
139 146
 
147
+	/**
148
+	 * @param \Closure $callable
149
+	 * @param integer $initial
150
+	 */
140 151
 	public static function iterator_reduce($iterable, $callable, $initial = null)
141 152
 	{
142 153
 		$returnValue = $initial;
@@ -171,6 +182,9 @@  discard block
 block discarded – undo
171 182
 		}
172 183
 	}
173 184
 
185
+	/**
186
+	 * @return string
187
+	 */
174 188
 	public static function getCurrentAndAdvance(&$iterable, $options = array())
175 189
 	{
176 190
 		if(is_array($iterable)) {
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use UnexpectedValueException;
6 6
 use ArrayIterator;
7
-use Exception;
8 7
 use InvalidArgumentException;
9 8
 use Iterator;
10 9
 use IteratorAggregate;
Please login to merge, or discard this patch.
src/itertools/LockingIterator.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace itertools;
4 4
 
5
-use ArrayIterator;
6 5
 use Exception;
7 6
 use IteratorIterator;
8 7
 
Please login to merge, or discard this patch.
Doc Comments   +5 added lines patch added patch discarded remove patch
@@ -12,6 +12,11 @@
 block discarded – undo
12 12
     protected $dir;
13 13
     protected $lockNameMapper;
14 14
 
15
+    /**
16
+     * @param RangeIterator $iterable
17
+     * @param string $dir
18
+     * @param \Closure $lockNameMapper
19
+     */
15 20
     public function __construct($iterable, $dir, $lockNameMapper = null)
16 21
     {
17 22
         parent::__construct(IterUtil::asTraversable($iterable));
Please login to merge, or discard this patch.
src/itertools/LookAheadIterator.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -59,6 +59,9 @@
 block discarded – undo
59 59
         return parent::current();
60 60
     }
61 61
 
62
+    /**
63
+     * @param integer $prefetchCount
64
+     */
62 65
     public function prefetchUpTo($prefetchCount)
63 66
     {
64 67
         $this->autoRewind();
Please login to merge, or discard this patch.
src/itertools/MapIterator.php 1 patch
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -4,8 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use InvalidArgumentException;
6 6
 use IteratorIterator;
7
-use Traversable;
8
-use ArrayIterator;
9 7
 
10 8
 
11 9
 /**
Please login to merge, or discard this patch.
src/itertools/PDOStatementIterator.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use Iterator;
6 6
 use PDO;
7
-use PDOStatement;
8 7
 
9 8
 
10 9
 class PDOStatementIterator implements Iterator
Please login to merge, or discard this patch.