Package com.mongodb.connection
Class BulkWriteBatchCombiner
- java.lang.Object
-
- com.mongodb.connection.BulkWriteBatchCombiner
-
Deprecated.
@Deprecated public class BulkWriteBatchCombiner extends Object
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 voidaddErrorResult(MongoBulkWriteException exception, com.mongodb.internal.connection.IndexMap indexMap)Deprecated.Add an error resultvoidaddErrorResult(List<BulkWriteError> writeErrors, WriteConcernError writeConcernError, com.mongodb.internal.connection.IndexMap indexMap)Deprecated.Add a list of error results and a write concern errorvoidaddResult(BulkWriteResult result, com.mongodb.internal.connection.IndexMap indexMap)Deprecated.Add a resultvoidaddWriteConcernErrorResult(WriteConcernError writeConcernError)Deprecated.Add a write concern error resultvoidaddWriteErrorResult(BulkWriteError writeError, com.mongodb.internal.connection.IndexMap indexMap)Deprecated.Add a write error resultMongoBulkWriteExceptiongetError()Deprecated.Gets the combined errors as an exceptionBulkWriteResultgetResult()Deprecated.Gets the combined result.booleanhasErrors()Deprecated.Gets whether there are errors in the combined result.booleanshouldStopSendingMoreBatches()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
-
-