Module spring.data.mongodb
Class ConditionalOperators.Switch.CaseOperator
java.lang.Object
org.springframework.data.mongodb.core.aggregation.ConditionalOperators.Switch.CaseOperator
- All Implemented Interfaces:
AggregationExpression,MongoExpression
- Enclosing class:
- ConditionalOperators.Switch
public static class ConditionalOperators.Switch.CaseOperator
extends Object
implements AggregationExpression
Encapsulates the aggregation framework case document inside a
$switch-operation.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interface -
Method Summary
Modifier and TypeMethodDescriptionorg.bson.DocumenttoDocument(AggregationOperationContext context) when(AggregationExpression condition) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.data.mongodb.core.aggregation.AggregationExpression
toDocument
-
Method Details
-
when
public static ConditionalOperators.Switch.CaseOperator.ThenBuilder when(AggregationExpression condition) -
toDocument
Description copied from interface:AggregationExpression- Specified by:
toDocumentin interfaceAggregationExpression- Parameters:
context- must not be null.- Returns:
- the MongoDB native (
Document) form of the expression.
-