Package com.mongodb.connection
Class BulkWriteBatchCombiner
- java.lang.Object
-
- com.mongodb.connection.BulkWriteBatchCombiner
-
@Deprecated public class BulkWriteBatchCombiner extends Object
Deprecated.This class is not part of the public API. It may be changed or removed at any time.
-
-
Constructor Summary
Constructors Constructor Description BulkWriteBatchCombiner(ServerAddress serverAddress, boolean ordered, WriteConcern writeConcern)
Deprecated.Construct an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
addErrorResult(MongoBulkWriteException exception, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add an error resultvoid
addErrorResult(List<BulkWriteError> writeErrors, WriteConcernError writeConcernError, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add a list of error results and a write concern errorvoid
addResult(BulkWriteResult result, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add a resultvoid
addWriteConcernErrorResult(WriteConcernError writeConcernError)
Deprecated.Add a write concern error resultvoid
addWriteErrorResult(BulkWriteError writeError, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add a write error resultMongoBulkWriteException
getError()
Deprecated.Gets the combined errors as an exceptionBulkWriteResult
getResult()
Deprecated.Gets the combined result.boolean
hasErrors()
Deprecated.Gets whether there are errors in the combined result.boolean
shouldStopSendingMoreBatches()
Deprecated.True if ordered and has write errors.
-
-
-
Constructor Detail
-
BulkWriteBatchCombiner
public BulkWriteBatchCombiner(ServerAddress serverAddress, boolean ordered, WriteConcern writeConcern)
Deprecated.Construct an instance.- Parameters:
serverAddress
- the server addressordered
- orderedwriteConcern
- the write concern
-
-
Method Detail
-
addResult
public void addResult(BulkWriteResult result, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add a result- Parameters:
result
- the resultindexMap
- the index map
-
addErrorResult
public void addErrorResult(MongoBulkWriteException exception, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add an error result- Parameters:
exception
- the exceptionindexMap
- the index map
-
addWriteErrorResult
public void addWriteErrorResult(BulkWriteError writeError, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add a write error result- Parameters:
writeError
- the write errorindexMap
- the index map
-
addWriteConcernErrorResult
public void addWriteConcernErrorResult(WriteConcernError writeConcernError)
Deprecated.Add a write concern error result- Parameters:
writeConcernError
- the write concern error
-
addErrorResult
public void addErrorResult(List<BulkWriteError> writeErrors, WriteConcernError writeConcernError, com.mongodb.internal.connection.IndexMap indexMap)
Deprecated.Add a list of error results and a write concern error- Parameters:
writeErrors
- the errorswriteConcernError
- the write concern errorindexMap
- the index map
-
getResult
public BulkWriteResult getResult()
Deprecated.Gets the combined result.- Returns:
- the result
-
shouldStopSendingMoreBatches
public boolean shouldStopSendingMoreBatches()
Deprecated.True if ordered and has write errors.- Returns:
- true if no more batches should be sent
-
hasErrors
public boolean hasErrors()
Deprecated.Gets whether there are errors in the combined result.- Returns:
- whether there are errors in the combined result
-
getError
public MongoBulkWriteException getError()
Deprecated.Gets the combined errors as an exception- Returns:
- the bulk write exception, or null if there were no errors
-
-