Package com.mongodb.client.model
Class UnwindOptions
-
- com.mongodb.client.model.UnwindOptions
-
public final class UnwindOptions extends
The options for an unwind aggregation pipeline stage- Since:
- 3.2
- MongoDB documentation
- Since server release
-
-
Constructor Summary
Constructors Constructor Description UnwindOptions()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description getIncludeArrayIndex()
Gets the includeArrayIndex field if set or nullUnwindOptions
arrayIndexFieldName)
Sets the field to be used to store the array index of the unwound itemisPreserveNullAndEmptyArrays()
If true the unwind stage will include documents that have null values or empty arraysUnwindOptions
preserveNullAndEmptyArrays)
Sets true if the unwind stage should include documents that have null values or empty arraystoString()
-
-
-
Method Detail
-
isPreserveNullAndEmptyArrays
@Nullable public isPreserveNullAndEmptyArrays()
If true the unwind stage will include documents that have null values or empty arrays- Returns:
- the preserve null values and empty arrays value or null
-
preserveNullAndEmptyArrays
public UnwindOptions preserveNullAndEmptyArrays(@Nullable preserveNullAndEmptyArrays)
Sets true if the unwind stage should include documents that have null values or empty arrays- Parameters:
preserveNullAndEmptyArrays
- flag depicting if the unwind stage should include documents that have null values or empty arrays- Returns:
- this
-
getIncludeArrayIndex
@Nullable public getIncludeArrayIndex()
Gets the includeArrayIndex field if set or null- Returns:
- the includeArrayIndex field if set or null
-
includeArrayIndex
public UnwindOptions includeArrayIndex(@Nullable arrayIndexFieldName)
Sets the field to be used to store the array index of the unwound item- Parameters:
arrayIndexFieldName
- the field to be used to store the array index of the unwound item- Returns:
- this
-
toString
public toString()
- Overrides:
in class
-
-