protected function normalizeLogical($operator)
    {
        switch (strtolower($operator)) {
            case '&&':
            case 'and':
                return 'and';
            case '||':
            case 'or':
                return 'or';
            default:
                throw new QueryException(sprintf('Query does not supports logical operator "%s" in query "%s"', $operator, $this->model()->entity()));
        }
    }
protected function normalizeLogical($operator)
    {
        switch (strtolower($operator)) {
            case '&&':
            case 'and':
                return 'and';
            case '||':
            case 'or':
                return 'or';
            default:
                throw new QueryException(sprintf('Query does not supports logical operator "%s" in query "%s"', $operator, $this->model()->entity()));
        }
    }
protected function normalizeLogical ( $ operator ) { switch ( strtolower ( $ operator ) ) { case '&&' : case 'and' : return 'and' ; case '||' : case 'or' : return 'or' ; default : throw new QueryException ( sprintf ( 'Query does not supports logical operator "%s" in query "%s"' , $ operator , $ this -> model ( ) -> entity ( ) ) ) ; } }
Asserts correct logical operation

@param string $operator

@return string
@throws QueryException
Asserts correct logical operation