- All Known Subinterfaces:
ExposesSubqueryCall.BuildableSubquery,LoadCSVStatementBuilder,StatementBuilder,StatementBuilder.BuildableMatchAndUpdate,StatementBuilder.BuildableOngoingMergeAction,StatementBuilder.OngoingInQueryCallWithReturnFields,StatementBuilder.OngoingMatchAndUpdate,StatementBuilder.OngoingMerge,StatementBuilder.OngoingReading,StatementBuilder.OngoingReadingAndWith,StatementBuilder.OngoingReadingAndWithWithSkip,StatementBuilder.OngoingReadingAndWithWithWhereAndOrder,StatementBuilder.OngoingReadingWithoutWhere,StatementBuilder.OngoingReadingWithWhere,StatementBuilder.OngoingStandaloneCallWithReturnFields,StatementBuilder.OngoingUpdate,StatementBuilder.OrderableOngoingReadingAndWith,StatementBuilder.OrderableOngoingReadingAndWithWithoutWhere,StatementBuilder.OrderableOngoingReadingAndWithWithWhere,StatementBuilder.VoidCall
@API(status=STABLE,
since="2023.0.0")
public interface ExposesWith
A step that exposes the
WITH clause. This interface used to be part of the
StatementBuilder and moved out of it to unify the WITH clause taking
in identifable elements.- Since:
- 2023.0.0
- Author:
- Michael J. Simons
-
Method Summary
Modifier and TypeMethodDescriptionStarts a with clause by passing variables to it.with(Collection<IdentifiableElement> elements) Create a match that returns one or more identifiable elements.with(IdentifiableElement... elements) Create a match that returns one or more identifiable elements.withDistinct(String... variables) Create a match that returns the distinct set of one or more identifiable elements.withDistinct(Collection<IdentifiableElement> expressions) Create a match that returns the distinct set of one or more expressions.withDistinct(IdentifiableElement... elements) Create a match that returns the distinct set of one or more identifiable elements.
-
Method Details
-
with
@CheckReturnValue default StatementBuilder.OrderableOngoingReadingAndWithWithoutWhere with(String... variables) Starts a with clause by passing variables to it.- Parameters:
variables- the variables to pass on to the next part- Returns:
- a match that can be build now
-
with
@CheckReturnValue default StatementBuilder.OrderableOngoingReadingAndWithWithoutWhere with(IdentifiableElement... elements) Create a match that returns one or more identifiable elements.- Parameters:
elements- the variables to pass on to the next part- Returns:
- a match that can be build now
-
with
@CheckReturnValue StatementBuilder.OrderableOngoingReadingAndWithWithoutWhere with(Collection<IdentifiableElement> elements) Create a match that returns one or more identifiable elements.- Parameters:
elements- the expressions to be returned. Must not be null and be at least one expression.- Returns:
- a match that can be build now
-
withDistinct
@CheckReturnValue default StatementBuilder.OrderableOngoingReadingAndWithWithoutWhere withDistinct(String... variables) Create a match that returns the distinct set of one or more identifiable elements.- Parameters:
variables- the variables to pass on to the next part- Returns:
- a match that can be build now
- See Also:
-
withDistinct
@CheckReturnValue default StatementBuilder.OrderableOngoingReadingAndWithWithoutWhere withDistinct(IdentifiableElement... elements) Create a match that returns the distinct set of one or more identifiable elements.- Parameters:
elements- the variables to pass on to the next part- Returns:
- a match that can be build now
- See Also:
-
withDistinct
@CheckReturnValue StatementBuilder.OrderableOngoingReadingAndWithWithoutWhere withDistinct(Collection<IdentifiableElement> expressions) Create a match that returns the distinct set of one or more expressions.- Parameters:
expressions- the expressions to be returned. Must not be null and be at least one expression.- Returns:
- a match that can be build now
-