ExpressionProtocol

public protocol ExpressionProtocol

Query expression.

  • Creates a multiply expression to multiply the current expression by the given expression.

    Declaration

    Swift

    func multiply(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be multipled by.

    Return Value

    A multiply expression.

  • Creates a divide expression to divide the current expression by the given expression.

    Declaration

    Swift

    func divide(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be devided by.

    Return Value

    A divide expression.

  • Creates a modulo expression to modulo the current expression by the given expression.

    Declaration

    Swift

    func modulo(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be moduloed by.

    Return Value

    A modulo expression.

  • Creates an add expression to add the given expression to the current expression.

    Declaration

    Swift

    func add(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to add to the current expression.

    Return Value

    An add expression.

  • Creates a subtract expression to subtract the given expression from the current expression.

    Declaration

    Swift

    func subtract(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to substract from the current expression.

    Return Value

    A subtract expression.

  • Creates a less than expression that evaluates whether or not the current expression is less than the given expression.

    Declaration

    Swift

    func lessThan(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    A less than expression.

  • Creates a less than or equal to expression that evaluates whether or not the current expression is less than or equal to the given expression.

    Declaration

    Swift

    func lessThanOrEqualTo(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    A less than or equal to expression.

  • Creates a greater than expression that evaluates whether or not the current expression is greater than the given expression.

    Declaration

    Swift

    func greaterThan(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    A greater than expression.

  • Creates a greater than or equal to expression that evaluates whether or not the current expression is greater than or equal to the given expression.

    Declaration

    Swift

    func greaterThanOrEqualTo(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    A greater than or equal to expression.

  • Creates an equal to expression that evaluates whether or not the current expression is equal to the given expression.

    Declaration

    Swift

    func equalTo(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    An equal to expression.

  • Creates a NOT equal to expression that evaluates whether or not the current expression is not equal to the given expression.

    Declaration

    Swift

    func notEqualTo(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    A NOT equal to expression.

  • Creates a Like expression that evaluates whether or not the current expression is LIKE the given expression.

    Declaration

    Swift

    func like(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    A Like expression.

  • Creates a regex match expression that evaluates whether or not the current expression regex matches the given expression.

    Declaration

    Swift

    func regex(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    A regex match expression.

  • Creates an IS expression that evaluates whether or not the current expression is equal to the given expression.

    Declaration

    Swift

    func `is`(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    An IS expression.

  • Creates an IS NOT expression that evaluates whether or not the current expression is not equal to the given expression.

    Declaration

    Swift

    func isNot(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to be compared with the current expression.

    Return Value

    An IS NOT expression.

  • Creates an IS NULL OR MISSING expression that evaluates whether or not the current expression is null or missing.

    Declaration

    Swift

    @available(*, deprecated, message: "Use isNotValued(﹚ instead.")
    func isNullOrMissing() -> ExpressionProtocol

    Return Value

    An IS NULL expression.

  • Creates an IS NOT NULL OR MISSING expression that evaluates whether or not the current expression is NOT null or missing.

    Declaration

    Swift

    @available(*, deprecated, message: "Use isValued(﹚ instead.")
    func notNullOrMissing() -> ExpressionProtocol

    Return Value

    An IS NOT NULL expression.

  • Creates an IS VALUED expression that evaluates whether or not the current expression is NOT null or missing.

    Declaration

    Swift

    func isValued() -> ExpressionProtocol

    Return Value

    The IS VALUED expression.

  • Creates an IS NOT VALUED expression that evaluates whether or not the current expression is null or missing.

    Declaration

    Swift

    func isNotValued() -> ExpressionProtocol

    Return Value

    The IS NOT VALUED expression.

  • Creates a logical AND expression that performs logical AND operation with the current expression.

    Declaration

    Swift

    func and(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to AND with the current expression.

    Return Value

    A logical AND expression.

  • Creates a logical OR expression that performs logical OR operation with the current expression.

    Declaration

    Swift

    func or(_ expression: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression

    The expression to OR with the current expression.

    Return Value

    A logical OR Expression.

  • Creates a between expression that evaluates whether or not the current expression is between the given expressions inclusively.

    Declaration

    Swift

    func between(_ expression1: ExpressionProtocol, and expression2: ExpressionProtocol) -> ExpressionProtocol

    Parameters

    expression1

    The inclusive lower bound expression.

    expression2

    The inclusive upper bound expression.

    Return Value

    A BETWEEN expression.

  • Creates an IN expression that evaluates whether or not the current expression is in the given expressions.

    Declaration

    Swift

    func `in`(_ expressions: [ExpressionProtocol]) -> ExpressionProtocol

    Parameters

    expressions

    The expression array to be evaluated with.

    Return Value

    An IN exprssion.

  • Creates a Collate expression with the given Collation specification. Commonly the collate expression is used in the Order BY clause or the string comparison expression (e.g. equalTo or lessThan) to specify how the two strings are compared.

    Declaration

    Swift

    func collate(_ collation: CollationProtocol) -> ExpressionProtocol

    Parameters

    collation

    The collation object.

    Return Value

    A Collate expression.