Returns an instance of SoqlExpression interface, dependent on
the given string, an plain Expression (fieldname), Function() or
AggregateFunction()

@param string $right
@return \Codemitte\ForceToolkit\Soql\AST\SoqlExpression
540416
private function buildRightExpression($right)
    {
        // BASIC TYPE CHECK. POSSIBLE VALUES:
        // array() [collection value]
        // string: INLINE QUERY, OR FORMULA, OR VARIABLE
        if(self::CONTEXT_HAVING === $this->getContext())
        {
            return $this->parser->parseRightHavingSoql($right);
        }
        return $this->parser->parseRightWhereSoql($right);
    }
654981
public BooleanExpression goe(Expression<T> right) {
        return Expressions.booleanOperation(Ops.GOE, mixin, right);
    }
1064592
public function stringExpression()
    {
        $lookaheadType = $this->lexer->lookahead['type'];

        switch ($lookaheadType) {
            case Lexer::T_IDENTIFIER:
                return $this->identificationVariable();

            case Lexer::T_STRING:
                $this->match(Lexer::T_STRING);
                return new LiteralNode(LiteralNode::STRING, $this->lexer->token['value']);
        }

        $this->syntaxError(
            'StateFieldPathExpression | string'
        );

        return null;
    }
504746
public function getFirstExpression()
    {
        $returnValue = null;

        
        if(empty($this->firstExpression)){
        	$property = new core_kernel_classes_Property(RulesRdf::PROPERTY_FIRST_EXPRESSION);
			$this->firstExpression = new core_kernel_rules_Expression($this->getUniquePropertyValue($property)->getUri());
        }
		$returnValue = $this->firstExpression;
        

        return $returnValue;
    }
1156343
public function setRightValue($right)
    {
        $this->right = $right;
        if (isset($this->nestedSetNode)) {
            $this->nestedSetNode->setRightValue($right);
        }
        return $this;
    }
1288412
function where($left, $operator = Query::EQUAL, $right = null, $quote = null) {
		if (func_num_args() === 1) {
			return $this->addAnd($left);
		}
		return $this->addAnd($left, $right, $operator, $quote);
	}
170466
public function onArithmeticExpression($expressionType, $left, $right) {
        switch ($expressionType) {
            case ExpressionType::MULTIPLY:
                return $this->_prepareBinaryExpression(self::MULTIPLY, $left, $right);
                break;
            case ExpressionType::DIVIDE:
                return $this->_prepareBinaryExpression(self::DIVIDE, $left, $right);
                break;
            case ExpressionType::MODULO:
                return $this->_prepareBinaryExpression(self::MODULO, $left, $right);
                break;
            case ExpressionType::ADD:
                return $this->_prepareBinaryExpression(self::ADD, $left, $right);
                break;
            case ExpressionType::SUBTRACT:
                return $this->_prepareBinaryExpression(self::SUBTRACT, $left, $right);
                break;
            default:
                throw new \InvalidArgumentException('onArithmeticExpression');
        }
    }
785985
public function rightJoinOn($table, $where)
    {
        //argument test
        Argument::i()
            //Argument 1 must be a string
            ->test(1, 'string')
            //Argument 2 must be a string
            ->test(2, 'string');
        
        $where = func_get_args();
        $table = array_shift($where);
        
        $this->join[] = array(self::RIGHT, $table, $where, false);
        
        return $this;
    }
1119573
public function operate( Expression $left, Expression $right ) {
		$typeSpec = self::$opTypes[$this->name];

		$leftType = self::$typeSpecMap[$typeSpec[0]];
		$rightType = self::$typeSpecMap[$typeSpec[1]];
		$resultType = self::$typeSpecMap[$typeSpec[2]];

		$start = min( $this->pos, $left->pos, $right->pos );
		$end = max( $this->end, $left->end, $right->end );
		$length = $end - $start;

		$newExpr = new Expression( $this->parser, $resultType,
			"{$left->rpn} {$right->rpn} {$this->name}",
			$start, $length );

		if ( !$left->isType( $leftType ) ) {
			$newExpr->error( "invalid type for left operand: expected $leftType, got {$left->type}" );
		}

		if ( !$right->isType( $rightType ) ) {
			$newExpr->error( "invalid type for right operand: expected $rightType, got {$right->type}" );
		}

		return $newExpr;
	}
590712
public static function expr() : ExpressionBuilder
    {
        if (self::$expressionBuilder === null) {
            self::$expressionBuilder = new ExpressionBuilder();
        }

        return self::$expressionBuilder;
    }
299914
public function having($left, $right, $comparator = Cmp::EQ, $conjunction = Cmp::CONJUNCTION_AND)
    {
        $left = ($left instanceof Expression) ? $left : new Expr\Column($left);
        $right = ($right instanceof Expression) ? $right : new Expr\Parameter($right);
        
        return $this->addHavingCondition($left, $right, $comparator, $conjunction);
    }
1059599
public final <A extends Number & Comparable<?>> BooleanExpression loe(Expression<A> right) {
        return Expressions.booleanOperation(Ops.LOE, mixin, right);
    }
765125
public BooleanExpression or(@Nullable Predicate right) {
        right = (Predicate) ExpressionUtils.extract(right);
        if (right != null) {
            return Expressions.booleanOperation(Ops.OR, mixin, right);
        } else {
            return this;
        }
    }
289116
public function useMinimumMatchFromTypoScript(): QueryBuilder
    {
        $searchConfiguration = $this->typoScriptConfiguration->getSearchConfiguration();
        if (!empty($searchConfiguration['query.']['minimumMatch'])) {
            return $this->useMinimumMatch($searchConfiguration['query.']['minimumMatch']);
        }

        return $this;
    }
1298380
public function rightJoin($table, callable $callable)
    {
        $table = $this->getPrefix().$table;

        if (is_null($this->join)) {
            $this->join = 'right join `'.$table.'`';

            if (is_callable($callable)) {
                $callable($this);
            }

            return $this;
        }

        if (!preg_match('/^(inner|left)\sjoin\s.*/', $this->join)) {
            $this->join .= ', `'.$table.'`';

            if (is_callable($callable)) {
                $callable($this);
            }

            return $this;
        }

        throw new QueryBuilderException(
            'The inner join clause is already initialized.',
            E_ERROR
        );
    }
18440
public function getDSQLExpression($expression)
    {
        $expr = $this->expr;
        if (is_callable($expr)) {
            $c = $this->expr;
            $expr = $c($this->owner, $expression);
        }

        if (is_string($expr)) {
            // If our Model has expr() method (inherited from Persistence\SQL) then use it
            if ($this->owner->hasMethod('expr')) {
                return $this->owner->expr('([])', [$this->owner->expr($expr)]);
            }

            // Otherwise call it from expression itself
            return $expression->expr('([])', [$expression->expr($expr)]);
        }

        return $expr;
    }
822533
public function getHelper()
    {
        return function($resolvedArgs, $exprArgs) {
            $text = $this->compiler->expression($exprArgs[0]['expr']);

            $length = '100';
            if (isset($exprArgs[1])) {
                $length = $this->compiler->expression($exprArgs[1]['expr']);
            }

            $endString = '"..."';
            if (isset($exprArgs[2])) {
                $endString = $this->compiler->expression($exprArgs[2]['expr']);
            }

            return '(new \Vegas\Tag\ShortenText())->prepare('.$text.','.$length.', '.$endString.')';
        };
    }