Interface ForeignAdapter<FE>

  • Type Parameters:
    FE - The type of the foreign expression.

    @API(status=EXPERIMENTAL,
         since="2021.1.0")
    public interface ForeignAdapter<FE>
    Represents an adapter that allows to turn foreign expressions into Cypher-DSL expressions.
    Since:
    2021.1.0
    Author:
    Michael J. Simons
    • Method Detail

      • asCondition

        Condition asCondition()
        Adapts a foreign expression into a Cypher-DSL Condition. The memoized expression should be something that can be evaluated into something boolean.
        Returns:
        A condition
        Throws:
        java.lang.IllegalArgumentException - if the expression doesn't resolve into something boolean
      • asExpression

        Expression asExpression()
        Adapts a foreign expression into a Cypher-DSL Expression.
        Returns:
        A native expression
      • asNode

        Node asNode()
        Adapts a foreign expression into a Cypher-DSL Node, that allows to to address it further down in queries.
        Returns:
        A node
        Throws:
        java.lang.IllegalArgumentException - if the expression doesn't describe something that can be used to describe a node
      • asRelationship

        Relationship asRelationship()
        Adapts a foreign expression into a Cypher-DSL Relationship, that allows to to address it further down in queries.
        Returns:
        A node
        Throws:
        java.lang.IllegalArgumentException - if the expression doesn't describe something that can be used to describe a node
      • asName

        SymbolicName asName()
        Adapts a foreign expression into a Cypher-DSL SymbolicName. The memoized expression should ideally be something that is named or resolves to an alias.
        Returns:
        A symbolic name
        Throws:
        java.lang.IllegalArgumentException - if a name cannot be derived from the expression.