Package org.neo4j.cypherdsl.core
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-DSLexpressions
.- Since:
- 2021.1.0
- Author:
- Michael J. Simons
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Condition
asCondition()
Adapts a foreign expression into a Cypher-DSLCondition
.Expression
asExpression()
Adapts a foreign expression into a Cypher-DSLExpression
.SymbolicName
asName()
Adapts a foreign expression into a Cypher-DSLSymbolicName
.Node
asNode()
Adapts a foreign expression into a Cypher-DSLNode
, that allows to to address it further down in queries.Relationship
asRelationship()
Adapts a foreign expression into a Cypher-DSLRelationship
, that allows to to address it further down in queries.
-
-
-
Method Detail
-
asCondition
Condition asCondition()
Adapts a foreign expression into a Cypher-DSLCondition
. 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-DSLExpression
.- Returns:
- A native expression
-
asNode
Node asNode()
Adapts a foreign expression into a Cypher-DSLNode
, 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-DSLRelationship
, 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-DSLSymbolicName
. 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.
-
-