Class BulkWriteBatchCombiner


  • @Deprecated
    public class BulkWriteBatchCombiner
    extends java.lang.Object
    Deprecated.
    This class is not part of the public API. It may be changed or removed at any time.
    • Constructor Detail

      • BulkWriteBatchCombiner

        public BulkWriteBatchCombiner​(ServerAddress serverAddress,
                                      boolean ordered,
                                      WriteConcern writeConcern)
        Deprecated.
        Construct an instance.
        Parameters:
        serverAddress - the server address
        ordered - ordered
        writeConcern - the write concern
    • Method Detail

      • addResult

        public void addResult​(BulkWriteResult result,
                              IndexMap indexMap)
        Deprecated.
        Add a result
        Parameters:
        result - the result
        indexMap - the index map
      • addErrorResult

        public void addErrorResult​(MongoBulkWriteException exception,
                                   IndexMap indexMap)
        Deprecated.
        Add an error result
        Parameters:
        exception - the exception
        indexMap - the index map
      • addWriteErrorResult

        public void addWriteErrorResult​(BulkWriteError writeError,
                                        IndexMap indexMap)
        Deprecated.
        Add a write error result
        Parameters:
        writeError - the write error
        indexMap - 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​(java.util.List<BulkWriteError> writeErrors,
                                   WriteConcernError writeConcernError,
                                   IndexMap indexMap)
        Deprecated.
        Add a list of error results and a write concern error
        Parameters:
        writeErrors - the errors
        writeConcernError - the write concern error
        indexMap - 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