Field/AbstractField.php
protected function isInIncrementsOfRange($increments, $value)
    {
        $incrementsParts = explode('/', $increments);

        if ('*' === $incrementsParts[0]) {
            return (int) $value % $incrementsParts[1] === 0;
        }

        if (!$this->isInRange($incrementsParts[0], $value)) {
            return false;
        }

        $rangeParts = explode('-', $incrementsParts[0]);

        for ($i = $rangeParts[0]; $i <= $rangeParts[1]; $i += $incrementsParts[1]) {
            if ($i == $value) {
                return true;
            }
        }

        return false;
    }
protected function isInIncrementsOfRange($increments, $value)
    {
        $incrementsParts = explode('/', $increments);

        if ('*' === $incrementsParts[0]) {
            return (int) $value % $incrementsParts[1] === 0;
        }

        if (!$this->isInRange($incrementsParts[0], $value)) {
            return false;
        }

        $rangeParts = explode('-', $incrementsParts[0]);

        for ($i = $rangeParts[0]; $i <= $rangeParts[1]; $i += $incrementsParts[1]) {
            if ($i == $value) {
                return true;
            }
        }

        return false;
    }
protected function isInIncrementsOfRange ( $ increments , $ value ) { $ incrementsParts = explode ( '/' , $ increments ) ; if ( '*' === $ incrementsParts [ 0 ] ) { return ( int ) $ value % $ incrementsParts [ 1 ] === 0 ; } if ( ! $ this -> isInRange ( $ incrementsParts [ 0 ] , $ value ) ) { return false ; } $ rangeParts = explode ( '-' , $ incrementsParts [ 0 ] ) ; for ( $ i = $ rangeParts [ 0 ] ; $ i <= $ rangeParts [ 1 ] ; $ i += $ incrementsParts [ 1 ] ) { if ( $ i == $ value ) { return true ; } } return false ; }
Checks if the given value is in the given increments of range.

@param string $increments
@param string $value

@return Boolean
Checks if the given value is in the given increments of range .