public function getLimit(array $query = [])
    {
        if (isset($query['limit']) && is_numeric($query['limit']) && in_array($query['limit'], self::$limits)) {
            return (int) $query['limit'];
        }

        return self::DEFAULT_LIMIT;
    }
public function getLimit(array $query = [])
    {
        if (isset($query['limit']) && is_numeric($query['limit']) && in_array($query['limit'], self::$limits)) {
            return (int) $query['limit'];
        }

        return self::DEFAULT_LIMIT;
    }
public function getLimit ( array $ query = [ ] ) { if ( isset ( $ query [ 'limit' ] ) && is_numeric ( $ query [ 'limit' ] ) && in_array ( $ query [ 'limit' ] , self :: $ limits ) ) { return ( int ) $ query [ 'limit' ] ; } return self :: DEFAULT_LIMIT ; }
Get limit list items.

@param array $query

@return int
Get limit list items .