@@ -148,7 +148,7 @@ public function key()
148
148
public function next ()
149
149
{
150
150
do {
151
- if (++ $ this ->ordinal >= $ this ->ordinalMax ) {
151
+ if (++$ this ->ordinal >= $ this ->ordinalMax ) {
152
152
$ this ->ordinal = $ this ->ordinalMax ;
153
153
return ;
154
154
}
@@ -218,8 +218,8 @@ public function getBitset()
218
218
*/
219
219
public function setBitset ($ bitset )
220
220
{
221
- if (! is_string ($ bitset )) {
222
- throw new InvalidArgumentException (" bitset must be a string" );
221
+ if (!is_string ($ bitset )) {
222
+ throw new InvalidArgumentException (' Bitset must be a string' );
223
223
}
224
224
225
225
$ bitset = strrev ($ bitset );
@@ -239,9 +239,9 @@ public function setBitset($bitset)
239
239
}
240
240
241
241
/**
242
- * get a bit at the given ordinal
242
+ * Get a bit at the given ordinal number
243
243
*
244
- * @param $ordinal int Number of bit to get
244
+ * @param $ordinal int Ordinal number of bit to get
245
245
* @return boolean
246
246
*/
247
247
private function getBit ($ ordinal )
@@ -250,10 +250,9 @@ private function getBit($ordinal)
250
250
}
251
251
252
252
/**
253
- * set a bit at the given ordinal
253
+ * Set a bit at the given ordinal number
254
254
*
255
- * @param $ordinal int
256
- * number of bit to manipulate
255
+ * @param $ordinal int Ordnal number of bit to set
257
256
* @return void
258
257
*/
259
258
private function setBit ($ ordinal )
@@ -263,15 +262,14 @@ private function setBit($ordinal)
263
262
}
264
263
265
264
/**
266
- * reset a bit at the given ordinal
265
+ * Unset a bit at the given ordinal number
267
266
*
268
- * @param $ordinal int
269
- * number of bit to set to false
267
+ * @param $ordinal int Ordinal number of bit to unset
270
268
* @return void
271
269
*/
272
270
private function unsetBit ($ ordinal )
273
271
{
274
272
$ byte = (int ) ($ ordinal / 8 );
275
- $ this ->bitset [$ byte ] = $ this ->bitset [$ byte ] & chr (~ (1 << ($ ordinal % 8 )));
273
+ $ this ->bitset [$ byte ] = $ this ->bitset [$ byte ] & chr (~(1 << ($ ordinal % 8 )));
276
274
}
277
275
}
0 commit comments