protected function isNestedCriteria(array $criterionData): bool
    {
        $isValid = true;

        foreach ($criterionData as $key => $possibleCriterion) {
            $isValid = $isValid &&
                (
                    (is_int($key) && is_array($possibleCriterion)) ||
                    ($key === Criterion::BOOLEAN && in_array($possibleCriterion, ['and', 'or']))
                );
        }

        return $isValid;
    }
protected function isNestedCriteria(array $criterionData): bool
    {
        $isValid = true;

        foreach ($criterionData as $key => $possibleCriterion) {
            $isValid = $isValid &&
                (
                    (is_int($key) && is_array($possibleCriterion)) ||
                    ($key === Criterion::BOOLEAN && in_array($possibleCriterion, ['and', 'or']))
                );
        }

        return $isValid;
    }
protected function isNestedCriteria ( array $ criterionData ) : bool { $ isValid = true ; foreach ( $ criterionData as $ key => $ possibleCriterion ) { $ isValid = $ isValid && ( ( is_int ( $ key ) && is_array ( $ possibleCriterion ) ) || ( $ key === Criterion :: BOOLEAN && in_array ( $ possibleCriterion , [ 'and' , 'or' ] ) ) ) ; } return $ isValid ; }
Shows whether given criterion data is nested.

@param array $criterionData Criterion data to check

@return boolean
Shows whether given criterion data is nested .