Package com.mongodb.client.model
Class DBCollectionFindAndModifyOptions
- java.lang.Object
-
- com.mongodb.client.model.DBCollectionFindAndModifyOptions
-
@Deprecated(since="2021-05-27") public final class DBCollectionFindAndModifyOptions extends java.lang.ObjectDeprecated.Usage of this API is not supported in AEM as a Cloud Service.The oprtions for find and modify operations.- Since:
- 3.4
-
-
Constructor Summary
Constructors Constructor Description DBCollectionFindAndModifyOptions()Deprecated.Construct a new instance
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description DBCollectionFindAndModifyOptionsarrayFilters(java.util.List<? extends DBObject> arrayFilters)Deprecated.Sets the array filters optionDBCollectionFindAndModifyOptionsbypassDocumentValidation(java.lang.Boolean bypassDocumentValidation)Deprecated.Sets the bypassDocumentValidationDBCollectionFindAndModifyOptionscollation(Collation collation)Deprecated.Sets the collationjava.util.List<? extends DBObject>getArrayFilters()Deprecated.Returns the array filters optionjava.lang.BooleangetBypassDocumentValidation()Deprecated.Returns the bypassDocumentValidationCollationgetCollation()Deprecated.Returns the collation optionslonggetMaxTime(java.util.concurrent.TimeUnit timeUnit)Deprecated.Gets the maximum execution time on the server for this operation.DBObjectgetProjection()Deprecated.Returns the projectionDBObjectgetSort()Deprecated.Returns the sortDBObjectgetUpdate()Deprecated.Returns the updateWriteConcerngetWriteConcern()Deprecated.Returns the writeConcernbooleanisRemove()Deprecated.Returns the removebooleanisUpsert()Deprecated.Returns the upsertDBCollectionFindAndModifyOptionsmaxTime(long maxTime, java.util.concurrent.TimeUnit timeUnit)Deprecated.Sets the maximum execution time on the server for this operation.DBCollectionFindAndModifyOptionsprojection(DBObject projection)Deprecated.Sets the projectionDBCollectionFindAndModifyOptionsremove(boolean remove)Deprecated.Sets the removebooleanreturnNew()Deprecated.Returns the returnNewDBCollectionFindAndModifyOptionsreturnNew(boolean returnNew)Deprecated.Sets the returnNewDBCollectionFindAndModifyOptionssort(DBObject sort)Deprecated.Sets the sortDBCollectionFindAndModifyOptionsupdate(DBObject update)Deprecated.Sets the updateDBCollectionFindAndModifyOptionsupsert(boolean upsert)Deprecated.Sets the upsertDBCollectionFindAndModifyOptionswriteConcern(WriteConcern writeConcern)Deprecated.Sets the writeConcern
-
-
-
Method Detail
-
getProjection
@Nullable public DBObject getProjection()
Deprecated.Returns the projection- Returns:
- the projection
-
projection
public DBCollectionFindAndModifyOptions projection(@Nullable DBObject projection)
Deprecated.Sets the projection- Parameters:
projection- the projection- Returns:
- this
-
getSort
@Nullable public DBObject getSort()
Deprecated.Returns the sort- Returns:
- the sort
-
sort
public DBCollectionFindAndModifyOptions sort(@Nullable DBObject sort)
Deprecated.Sets the sort- Parameters:
sort- the sort- Returns:
- this
-
isRemove
public boolean isRemove()
Deprecated.Returns the remove- Returns:
- the remove
-
remove
public DBCollectionFindAndModifyOptions remove(boolean remove)
Deprecated.Sets the remove- Parameters:
remove- the remove- Returns:
- this
-
getUpdate
@Nullable public DBObject getUpdate()
Deprecated.Returns the update- Returns:
- the update
-
update
public DBCollectionFindAndModifyOptions update(@Nullable DBObject update)
Deprecated.Sets the update- Parameters:
update- the update- Returns:
- this
-
isUpsert
public boolean isUpsert()
Deprecated.Returns the upsert- Returns:
- the upsert
-
upsert
public DBCollectionFindAndModifyOptions upsert(boolean upsert)
Deprecated.Sets the upsert- Parameters:
upsert- the upsert- Returns:
- this
-
returnNew
public boolean returnNew()
Deprecated.Returns the returnNew- Returns:
- the returnNew
-
returnNew
public DBCollectionFindAndModifyOptions returnNew(boolean returnNew)
Deprecated.Sets the returnNew- Parameters:
returnNew- the returnNew- Returns:
- this
-
getBypassDocumentValidation
public java.lang.Boolean getBypassDocumentValidation()
Deprecated.Returns the bypassDocumentValidation- Returns:
- the bypassDocumentValidation
-
bypassDocumentValidation
public DBCollectionFindAndModifyOptions bypassDocumentValidation(java.lang.Boolean bypassDocumentValidation)
Deprecated.Sets the bypassDocumentValidation- Parameters:
bypassDocumentValidation- the bypassDocumentValidation- Returns:
- this
-
getMaxTime
public long getMaxTime(java.util.concurrent.TimeUnit timeUnit)
Deprecated.Gets the maximum execution time on the server for this operation. The default is 0, which places no limit on the execution time.- Parameters:
timeUnit- the time unit to return the result in- Returns:
- the maximum execution time in the given time unit
-
maxTime
public DBCollectionFindAndModifyOptions maxTime(long maxTime, java.util.concurrent.TimeUnit timeUnit)
Deprecated.Sets the maximum execution time on the server for this operation.- Parameters:
maxTime- the max timetimeUnit- the time unit, which may not be null- Returns:
- this
-
getWriteConcern
@Nullable public WriteConcern getWriteConcern()
Deprecated.Returns the writeConcern- Returns:
- the writeConcern
-
writeConcern
public DBCollectionFindAndModifyOptions writeConcern(@Nullable WriteConcern writeConcern)
Deprecated.Sets the writeConcern- Parameters:
writeConcern- the writeConcern- Returns:
- this
-
getCollation
public Collation getCollation()
Deprecated.Returns the collation options- Returns:
- the collation options
-
collation
public DBCollectionFindAndModifyOptions collation(Collation collation)
Deprecated.Sets the collation- Parameters:
collation- the collation- Returns:
- this
-
arrayFilters
public DBCollectionFindAndModifyOptions arrayFilters(java.util.List<? extends DBObject> arrayFilters)
Deprecated.Sets the array filters option- Parameters:
arrayFilters- the array filters, which may be null- Returns:
- this
- Since:
- 3.6
-
getArrayFilters
public java.util.List<? extends DBObject> getArrayFilters()
Deprecated.Returns the array filters option- Returns:
- the array filters, which may be null
- Since:
- 3.6
-
-