Package com.sap.cds.ql
Interface StructuredType<T extends StructuredType<T>>
- All Superinterfaces:
CqnSource,CqnToken,JSONizable,Selectable,Source<T>
Builder to define sets of structured CDS entities and types using filtered
path expressions, to define predicates on these sets, and to address elements
of structured types.
Note that some methods in this interface mutually exclude each other and
cannot be combined. For example, the methods
filter, filterByParams, and
matching all set the where condition of the enclosing
statement, overwriting any previously stored conditions.-
Method Summary
Modifier and TypeMethodDescription_all()Creates a predicate that tests whether all elements of the entity set referenced by this structured type match a given condition.Creates a predicate that tests whether all elements of the entity set referenced by this structured type match a given condition.Creates a predicate that tests whether any instance of the entity set referenced by this structured type matches a given condition.Creates a predicate that tests whether any instance of the entity set referenced by this structured type matches a given condition.Gives an alias to this structured type.asRef()Returns an immutable ref.eTag(CqnListValue values) exists()Creates a predicate that tests whether any instance of the entity set referenced by this structured type exists, i.e. the entity set referenced by this structured type is not empty.expand()expand(Selectable... items) expand(Iterable<? extends Selectable> items) expand(Function<T, ? extends Selectable> item) expand(Function<T, ? extends Selectable>... items) expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2) expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3) expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4) expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5) expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6) expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6, Function<T, ? extends Selectable> item7) expand(List<Function<T, ? extends Selectable>> items) filter(Function<T, CqnPredicate> p) default TfilterByParams(String... elementRefs) filterByParams(Collection<String> elementRefs) <E> ElementRef<E><E> ElementRef<E>inline()inline(Selectable... items) inline(Iterable<? extends Selectable> items) default CqnSelectListIteminline(Function<T, ? extends Selectable> item) default CqnSelectListIteminline(Function<T, ? extends Selectable>... items) default CqnSelectListIteminline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2) default CqnSelectListIteminline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3) default CqnSelectListIteminline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4) default CqnSelectListIteminline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5) default CqnSelectListIteminline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6) default CqnSelectListIteminline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6, Function<T, ? extends Selectable> item7) inline(List<Function<T, ? extends Selectable>> items) <E extends StructuredType<E>>
Ewhen(CqnPredicate pred) Starts a chain of when-then expressions.Methods inherited from interface com.sap.cds.ql.cqn.CqnSource
asJoin, asSelect, asTableFunction, isJoin, isRef, isSelect, isTableFunctionMethods inherited from interface com.sap.cds.JSONizable
toJson
-
Method Details
-
to
-
to
-
get
-
get
-
filter
-
filter
-
anyMatch
Creates a predicate that tests whether any instance of the entity set referenced by this structured type matches a given condition. The filter condition is provided as a function that accepts a model object representing the entity referenced by this structured type and returning the filter condition.- Parameters:
p- the condition to test for- Returns:
- the match predicate
-
anyMatch
Creates a predicate that tests whether any instance of the entity set referenced by this structured type matches a given condition.- Parameters:
p- the condition to test for- Returns:
- the match predicate
-
allMatch
Creates a predicate that tests whether all elements of the entity set referenced by this structured type match a given condition. The filter condition is provided as a function that accepts a model object representing the entity referenced by this structured type and returning the filter condition.- Parameters:
p- the condition to test for- Returns:
- the match predicate
-
allMatch
Creates a predicate that tests whether all elements of the entity set referenced by this structured type match a given condition.- Parameters:
p- the condition to test for- Returns:
- the match predicate
-
exists
Predicate exists()Creates a predicate that tests whether any instance of the entity set referenced by this structured type exists, i.e. the entity set referenced by this structured type is not empty.- Returns:
- the exists predicate
-
eTag
-
eTag
-
matching
-
filterByParams
-
filterByParams
-
inline
CqnSelectListItem inline() -
inline
-
inline
default CqnSelectListItem inline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2) -
inline
default CqnSelectListItem inline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3) -
inline
default CqnSelectListItem inline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4) -
inline
default CqnSelectListItem inline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5) -
inline
default CqnSelectListItem inline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6) -
inline
default CqnSelectListItem inline(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6, Function<T, ? extends Selectable> item7) -
inline
-
inline
-
inline
-
inline
-
inline
-
expand
-
expand
-
expand
default Expand<T> expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2) -
expand
default Expand<T> expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3) -
expand
default Expand<T> expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4) -
expand
default Expand<T> expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5) -
expand
default Expand<T> expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6) -
expand
default Expand<T> expand(Function<T, ? extends Selectable> item1, Function<T, ? extends Selectable> item2, Function<T, ? extends Selectable> item3, Function<T, ? extends Selectable> item4, Function<T, ? extends Selectable> item5, Function<T, ? extends Selectable> item6, Function<T, ? extends Selectable> item7) -
expand
-
expand
-
expand
-
expand
-
expand
-
_all
CqnSelectListItem _all() -
exists
-
asRef
StructuredTypeRef asRef()Returns an immutable ref.- Specified by:
asRefin interfaceCqnSource- Returns:
- the
StructuredTypeRef
-
as
Gives an alias to this structured type.- Parameters:
alias- the alias or null- Returns:
- this structured type
-
when
Starts a chain of when-then expressions.- Parameters:
pred- theconditionof the first case.- Returns:
- a builder to specify the case's return value
-