@@ -183,8 +183,8 @@ public function next()
183
183
* Go to the first valid iterator position.
184
184
* If no valid iterator position was found the iterator position will be 0.
185
185
* @return void
186
- * @see doRewindBin
187
- * @see doRewindInt
186
+ * @uses doRewindBin()
187
+ * @uses doRewindInt()
188
188
*/
189
189
public function rewind ()
190
190
{
@@ -198,8 +198,8 @@ public function rewind()
198
198
* This is the binary bitset implementation.
199
199
*
200
200
* @return void
201
- * @see rewind
202
- * @see doRewindInt
201
+ * @see rewind()
202
+ * @see doRewindInt()
203
203
*/
204
204
private function doRewindBin ()
205
205
{
@@ -218,8 +218,8 @@ private function doRewindBin()
218
218
* This is the binary bitset implementation.
219
219
*
220
220
* @return void
221
- * @see rewind
222
- * @see doRewindBin
221
+ * @see rewind()
222
+ * @see doRewindBin()
223
223
*/
224
224
private function doRewindInt ()
225
225
{
@@ -246,8 +246,8 @@ public function valid()
246
246
* Count the number of elements
247
247
*
248
248
* @return int
249
- * @see doCountBin
250
- * @see doCountInt
249
+ * @uses doCountBin()
250
+ * @uses doCountInt()
251
251
*/
252
252
public function count ()
253
253
{
@@ -260,8 +260,8 @@ public function count()
260
260
* This is the binary bitset implementation.
261
261
*
262
262
* @return int
263
- * @see count
264
- * @see doCountInt
263
+ * @see count()
264
+ * @see doCountInt()
265
265
*/
266
266
private function doCountBin ()
267
267
{
@@ -293,8 +293,8 @@ private function doCountBin()
293
293
* This is the integer bitset implementation.
294
294
*
295
295
* @return int
296
- * @see count
297
- * @see doCountBin
296
+ * @see count()
297
+ * @see doCountBin()
298
298
*/
299
299
private function doCountInt ()
300
300
{
@@ -376,6 +376,7 @@ public function isSuperset(EnumSet $other)
376
376
*
377
377
* @param EnumSet $other EnumSet of the same enumeration to produce the union
378
378
* @return EnumSet
379
+ * @throws InvalidArgumentException If $other doesn't match the enumeration
379
380
*/
380
381
public function union (EnumSet $ other )
381
382
{
@@ -396,6 +397,7 @@ public function union(EnumSet $other)
396
397
*
397
398
* @param EnumSet $other EnumSet of the same enumeration to produce the intersect
398
399
* @return EnumSet
400
+ * @throws InvalidArgumentException If $other doesn't match the enumeration
399
401
*/
400
402
public function intersect (EnumSet $ other )
401
403
{
@@ -416,6 +418,7 @@ public function intersect(EnumSet $other)
416
418
*
417
419
* @param EnumSet $other EnumSet of the same enumeration to produce the diff
418
420
* @return EnumSet
421
+ * @throws InvalidArgumentException If $other doesn't match the enumeration
419
422
*/
420
423
public function diff (EnumSet $ other )
421
424
{
@@ -436,6 +439,7 @@ public function diff(EnumSet $other)
436
439
*
437
440
* @param EnumSet $other EnumSet of the same enumeration to produce the symmetric difference
438
441
* @return EnumSet
442
+ * @throws InvalidArgumentException If $other doesn't match the enumeration
439
443
*/
440
444
public function symDiff (EnumSet $ other )
441
445
{
@@ -454,6 +458,8 @@ public function symDiff(EnumSet $other)
454
458
/**
455
459
* Get ordinal numbers of the defined enumerators as array
456
460
* @return int[]
461
+ * @uses doGetOrdinalsBin()
462
+ * @uses doGetOrdinalsInt()
457
463
*/
458
464
public function getOrdinals ()
459
465
{
@@ -466,8 +472,8 @@ public function getOrdinals()
466
472
* This is the binary bitset implementation.
467
473
*
468
474
* @return int[]
469
- * @see getOrdinals
470
- * @see goGetOrdinalsInt
475
+ * @see getOrdinals()
476
+ * @see goGetOrdinalsInt()
471
477
*/
472
478
private function doGetOrdinalsBin ()
473
479
{
@@ -496,8 +502,8 @@ private function doGetOrdinalsBin()
496
502
* This is the integer bitset implementation.
497
503
*
498
504
* @return int[]
499
- * @see getOrdinals
500
- * @see doGetOrdinalsBin
505
+ * @see getOrdinals()
506
+ * @see doGetOrdinalsBin()
501
507
*/
502
508
private function doGetOrdinalsInt ()
503
509
{
@@ -558,6 +564,8 @@ public function getEnumerators()
558
564
* Get binary bitset in little-endian order
559
565
*
560
566
* @return string
567
+ * @uses doGetBinaryBitsetLeBin()
568
+ * @uses doGetBinaryBitsetLeInt()
561
569
*/
562
570
public function getBinaryBitsetLe ()
563
571
{
@@ -570,6 +578,8 @@ public function getBinaryBitsetLe()
570
578
* This is the binary bitset implementation.
571
579
*
572
580
* @return string
581
+ * @see getBinaryBitsetLe()
582
+ * @see doGetBinaryBitsetLeInt()
573
583
*/
574
584
private function doGetBinaryBitsetLeBin ()
575
585
{
@@ -582,6 +592,8 @@ private function doGetBinaryBitsetLeBin()
582
592
* This is the integer bitset implementation.
583
593
*
584
594
* @return string
595
+ * @see getBinaryBitsetLe()
596
+ * @see doGetBinaryBitsetLeBin()
585
597
*/
586
598
private function doGetBinaryBitsetLeInt ()
587
599
{
@@ -597,7 +609,9 @@ private function doGetBinaryBitsetLeInt()
597
609
* @param string $bitset
598
610
* @return void
599
611
* @throws InvalidArgumentException On a non string is given as Parameter
600
- * @throws InvalidArgumentException On Out-Of-Range bits given as input bitset
612
+ * @throws InvalidArgumentException On out-of-range bits given as input bitset
613
+ * @uses doSetBinaryBitsetLeBin()
614
+ * @uses doSetBinaryBitsetLeInt()
601
615
*/
602
616
public function setBinaryBitsetLe ($ bitset )
603
617
{
@@ -618,7 +632,9 @@ public function setBinaryBitsetLe($bitset)
618
632
*
619
633
* @param string $bitset
620
634
* @return void
621
- * @throws InvalidArgumentException On Out-Of-Range bits given as input bitset
635
+ * @throws InvalidArgumentException On out-of-range bits given as input bitset
636
+ * @see setBinaryBitsetLeBin()
637
+ * @see doSetBinaryBitsetLeInt()
622
638
*/
623
639
private function doSetBinaryBitsetLeBin ($ bitset )
624
640
{
@@ -630,7 +646,7 @@ private function doSetBinaryBitsetLeBin($bitset)
630
646
$ bitset .= \str_repeat ("\0" , $ size - $ sizeIn );
631
647
} elseif ($ sizeIn > $ size ) {
632
648
if (\ltrim (\substr ($ bitset , $ size ), "\0" ) !== '' ) {
633
- throw new InvalidArgumentException ('Out-Of-Range bits detected ' );
649
+ throw new InvalidArgumentException ('out-of-range bits detected ' );
634
650
}
635
651
$ bitset = \substr ($ bitset , 0 , $ size );
636
652
}
@@ -641,7 +657,7 @@ private function doSetBinaryBitsetLeBin($bitset)
641
657
$ lastByte = $ bitset [$ size - 1 ];
642
658
$ lastByteExpected = \chr ((1 << $ lastByteMaxOrd ) - 1 ) & $ lastByte ;
643
659
if ($ lastByte !== $ lastByteExpected ) {
644
- throw new InvalidArgumentException ('Out-Of-Range bits detected ' );
660
+ throw new InvalidArgumentException ('out-of-range bits detected ' );
645
661
}
646
662
647
663
$ this ->bitset = \substr ($ bitset , 0 , -1 ) . $ lastByteExpected ;
@@ -657,7 +673,9 @@ private function doSetBinaryBitsetLeBin($bitset)
657
673
*
658
674
* @param string $bitset
659
675
* @return void
660
- * @throws InvalidArgumentException On Out-Of-Range bits given as input bitset
676
+ * @throws InvalidArgumentException On out-of-range bits given as input bitset
677
+ * @see setBinaryBitsetLeBin()
678
+ * @see doSetBinaryBitsetLeBin()
661
679
*/
662
680
private function doSetBinaryBitsetLeInt ($ bitset )
663
681
{
@@ -667,14 +685,14 @@ private function doSetBinaryBitsetLeInt($bitset)
667
685
$ ord = \ord ($ bitset [$ i ]);
668
686
669
687
if ($ ord && $ i > \PHP_INT_SIZE - 1 ) {
670
- throw new InvalidArgumentException ('Out-Of-Range bits detected ' );
688
+ throw new InvalidArgumentException ('out-of-range bits detected ' );
671
689
}
672
690
673
691
$ int |= $ ord << (8 * $ i );
674
692
}
675
693
676
694
if ($ int & (~0 << $ this ->ordinalMax )) {
677
- throw new InvalidArgumentException ('Out-Of-Range bits detected ' );
695
+ throw new InvalidArgumentException ('out-of-range bits detected ' );
678
696
}
679
697
680
698
$ this ->bitset = $ int ;
@@ -698,7 +716,7 @@ public function getBinaryBitsetBe()
698
716
* @param string $bitset
699
717
* @return void
700
718
* @throws InvalidArgumentException On a non string is given as Parameter
701
- * @throws InvalidArgumentException On Out-Of-Range bits given as input bitset
719
+ * @throws InvalidArgumentException On out-of-range bits given as input bitset
702
720
*/
703
721
public function setBinaryBitsetBe ($ bitset )
704
722
{
@@ -713,6 +731,9 @@ public function setBinaryBitsetBe($bitset)
713
731
*
714
732
* @param int $ordinal Ordinal number of bit to get
715
733
* @return bool
734
+ * @throws InvalidArgumentException If the given ordinal number is out-of-range
735
+ * @uses doGetBitBin()
736
+ * @uses doGetBitInt()
716
737
*/
717
738
public function getBit ($ ordinal )
718
739
{
@@ -730,8 +751,8 @@ public function getBit($ordinal)
730
751
*
731
752
* @param int $ordinal Ordinal number of bit to get
732
753
* @return bool
733
- * @see getBit
734
- * @see doGetBitInt
754
+ * @see getBit()
755
+ * @see doGetBitInt()
735
756
*/
736
757
private function doGetBitBin ($ ordinal )
737
758
{
@@ -745,8 +766,8 @@ private function doGetBitBin($ordinal)
745
766
*
746
767
* @param int $ordinal Ordinal number of bit to get
747
768
* @return bool
748
- * @see getBit
749
- * @see doGetBitBin
769
+ * @see getBit()
770
+ * @see doGetBitBin()
750
771
*/
751
772
private function doGetBitInt ($ ordinal )
752
773
{
@@ -756,13 +777,14 @@ private function doGetBitInt($ordinal)
756
777
/**
757
778
* Set a bit at the given ordinal number
758
779
*
759
- * @param int $ordinal Ordnal number of bit to set
780
+ * @param int $ordinal Ordinal number of bit to set
760
781
* @param bool $bit The bit to set
761
782
* @return void
762
- * @see doSetBitBin
763
- * @see doSetBitInt
764
- * @see doUnsetBin
765
- * @see doUnsetInt
783
+ * @throws InvalidArgumentException If the given ordinal number is out-of-range
784
+ * @uses doSetBitBin()
785
+ * @uses doSetBitInt()
786
+ * @uses doUnsetBitBin()
787
+ * @uses doUnsetBitInt()
766
788
*/
767
789
public function setBit ($ ordinal , $ bit )
768
790
{
@@ -782,10 +804,10 @@ public function setBit($ordinal, $bit)
782
804
*
783
805
* This is the binary bitset implementation.
784
806
*
785
- * @param int $ordinal Ordnal number of bit to set
807
+ * @param int $ordinal Ordinal number of bit to set
786
808
* @return void
787
- * @see setBit
788
- * @see doSetBitInt
809
+ * @see setBit()
810
+ * @see doSetBitInt()
789
811
*/
790
812
private function doSetBitBin ($ ordinal )
791
813
{
@@ -798,10 +820,10 @@ private function doSetBitBin($ordinal)
798
820
*
799
821
* This is the binary bitset implementation.
800
822
*
801
- * @param int $ordinal Ordnal number of bit to set
823
+ * @param int $ordinal Ordinal number of bit to set
802
824
* @return void
803
- * @see setBit
804
- * @see doSetBitBin
825
+ * @see setBit()
826
+ * @see doSetBitBin()
805
827
*/
806
828
private function doSetBitInt ($ ordinal )
807
829
{
@@ -815,8 +837,8 @@ private function doSetBitInt($ordinal)
815
837
*
816
838
* @param int $ordinal Ordinal number of bit to unset
817
839
* @return void
818
- * @see setBit
819
- * @see doUnsetBitInt
840
+ * @see setBit()
841
+ * @see doUnsetBitInt()
820
842
*/
821
843
private function doUnsetBitBin ($ ordinal )
822
844
{
@@ -831,8 +853,8 @@ private function doUnsetBitBin($ordinal)
831
853
*
832
854
* @param int $ordinal Ordinal number of bit to unset
833
855
* @return void
834
- * @see setBit
835
- * @see doUnsetBitBin
856
+ * @see setBit()
857
+ * @see doUnsetBitBin()
836
858
*/
837
859
private function doUnsetBitInt ($ ordinal )
838
860
{
0 commit comments