Package com.mongodb.client.model.mql
Class BranchesIntermediary<T extends MqlValue,R extends MqlValue>
java.lang.Object
com.mongodb.client.model.mql.BranchesTerminal<T,R>
com.mongodb.client.model.mql.BranchesIntermediary<T,R>
- Type Parameters:
T- the type of the values that may be checked.R- the type of the value produced.
@Beta(CLIENT)
public final class BranchesIntermediary<T extends MqlValue,R extends MqlValue>
extends BranchesTerminal<T,R>
See
Branches.- Since:
- 4.9.0
-
Method Summary
Modifier and TypeMethodDescriptionIf no other check succeeds, produces a value specified by themapping.A successful check for equality produces a value specified by themapping.A successful check for the specifiedpredicateproduces a value specified by themapping.<Q extends MqlValue>
BranchesIntermediary<T,R> isArray(Function<? super MqlArray<@MqlUnchecked(TYPE_ARGUMENT) Q>, ? extends R> mapping) A successful check for being an array produces a value specified by themapping.isBoolean(Function<? super MqlBoolean, ? extends R> mapping) A successful check for being a boolean produces a value specified by themapping.A successful check for being a date produces a value specified by themapping.isDocument(Function<? super MqlDocument, ? extends R> mapping) A successful check for being a document (or document-like value, seeMqlMapandMqlEntry) produces a value specified by themapping.isInteger(Function<? super MqlInteger, ? extends R> mapping) A successful check for being an integer produces a value specified by themapping.<Q extends MqlValue>
BranchesIntermediary<T,R> isMap(Function<? super MqlMap<@MqlUnchecked(TYPE_ARGUMENT) Q>, ? extends R> mapping) A successful check for being a map (or map-like value, seeMqlDocumentandMqlEntry) produces a value specified by themapping.A successful check for MqlValues.ofNull() being the null value} produces a value specified by themapping.A successful check for being a number produces a value specified by themapping.A successful check for being a string produces a value specified by themapping.A successful check for being less than the provided valuevproduces a value specified by themapping.A successful check for being less than or equal to the provided valuevproduces a value specified by themapping.
-
Method Details
-
is
public BranchesIntermediary<T,R> is(Function<? super T, MqlBoolean> predicate, Function<? super T, ? extends R> mapping) A successful check for the specifiedpredicateproduces a value specified by themapping.- Parameters:
predicate- the predicate.mapping- the mapping.- Returns:
- the appended sequence of checks.
-
eq
A successful check for equality produces a value specified by themapping.- Parameters:
v- the value to check against.mapping- the mapping.- Returns:
- the appended sequence of checks.
-
lt
A successful check for being less than the provided valuevproduces a value specified by themapping.- Parameters:
v- the value to check against.mapping- the mapping.- Returns:
- the appended sequence of checks.
-
lte
A successful check for being less than or equal to the provided valuevproduces a value specified by themapping.- Parameters:
v- the value to check against.mapping- the mapping.- Returns:
- the appended sequence of checks.
-
isBoolean
A successful check for being a boolean produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-
isNumber
A successful check for being a number produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
- Since server release
- 4.4
-
isInteger
A successful check for being an integer produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
- Since server release
- 4.4
-
isString
A successful check for being a string produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-
isDate
A successful check for being a date produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-
isArray
public <Q extends MqlValue> BranchesIntermediary<T,R> isArray(Function<? super MqlArray<@MqlUnchecked(TYPE_ARGUMENT) Q>, ? extends R> mapping) A successful check for being an array produces a value specified by themapping.Warning: The type argument of the array is not enforced by the API. The use of this method is an unchecked assertion that the type argument is correct.
- Type Parameters:
Q- the type of the elements of the resulting array.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-
isDocument
A successful check for being a document (or document-like value, seeMqlMapandMqlEntry) produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-
isMap
public <Q extends MqlValue> BranchesIntermediary<T,R> isMap(Function<? super MqlMap<@MqlUnchecked(TYPE_ARGUMENT) Q>, ? extends R> mapping) A successful check for being a map (or map-like value, seeMqlDocumentandMqlEntry) produces a value specified by themapping.Warning: The type argument of the map is not enforced by the API. The use of this method is an unchecked assertion that the type argument is correct.
- Type Parameters:
Q- the type of the array.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-
isNull
A successful check for MqlValues.ofNull() being the null value} produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-
defaults
If no other check succeeds, produces a value specified by themapping.- Parameters:
mapping- the mapping.- Returns:
- the appended sequence of checks.
-