Code Duplication    Length = 14-14 lines in 2 locations

src/Arrayy.php 2 locations

@@ 5885-5898 (lines=14) @@
5882
     *
5883
     * @return bool
5884
     */
5885
    public function sizeIsGreaterThan(int $size): bool
5886
    {
5887
        // init
5888
        $itemsTempCount = 0;
5889
5890
        foreach ($this->getGenerator() as $key => $value) {
5891
            ++$itemsTempCount;
5892
            if ($itemsTempCount > $size) {
5893
                return true;
5894
            }
5895
        }
5896
5897
        return $itemsTempCount > $size;
5898
    }
5899
5900
    /**
5901
     * Checks whether array has less than $size items.
@@ 5907-5920 (lines=14) @@
5904
     *
5905
     * @return bool
5906
     */
5907
    public function sizeIsLessThan(int $size): bool
5908
    {
5909
        // init
5910
        $itemsTempCount = 0;
5911
5912
        foreach ($this->getGenerator() as $key => $value) {
5913
            ++$itemsTempCount;
5914
            if ($itemsTempCount > $size) {
5915
                return false;
5916
            }
5917
        }
5918
5919
        return $itemsTempCount < $size;
5920
    }
5921
5922
    /**
5923
     * Counts all elements in an array, or something in an object.