Package oracle.nosql.driver.ops

# Class DeleteResult

java.lang.Object
oracle.nosql.driver.ops.Result
oracle.nosql.driver.ops.WriteResult
oracle.nosql.driver.ops.DeleteResult

public class DeleteResult extends WriteResult
Represents the result of a `NoSQLHandle.delete(oracle.nosql.driver.ops.DeleteRequest)` operation.

If the delete succeeded `getSuccess()` returns true. Information about the existing row may be available using `getExistingValue()`, .`getExistingVersion()` and `getExistingModificationTime()`, depending on the use of `DeleteRequest.setReturnRow(boolean)` and the result of the operation.

See Also:
  - `NoSQLHandle.delete(oracle.nosql.driver.ops.DeleteRequest)`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `DeleteResult()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `long`
  `getExistingModificationTime()`
  Returns the existing modification time if available.
  `MapValue`
  `getExistingValue()`
  Returns the existing row value if available.
  `Version`
  `getExistingVersion()`
  Returns the existing row `Version` if available.
  `int`
  `getReadKB()`
  Returns the read throughput consumed by this operation, in KBytes.
  `int`
  `getReadUnits()`
  Returns the read throughput consumed by this operation, in read units.
  `boolean`
  `getSuccess()`
  Returns true if the delete operation succeeded.
  `int`
  `getWriteKB()`
  Returns the write throughput consumed by this operation, in KBytes.
  `int`
  `getWriteUnits()`
  Returns the write throughput consumed by this operation, in write units.
  `String`
  `toString()`

  ### Methods inherited from class oracle.nosql.driver.ops.Result

  `getRateLimitDelayedMs, getRetryStats`

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### DeleteResult

    public DeleteResult()

- ## Method Details

  - ### getSuccess

    public boolean getSuccess()
    Returns true if the delete operation succeeded.
    Returns:
      true if the operation succeeded

  - ### getExistingVersion

    public Version getExistingVersion()
    Returns the existing row `Version` if available. This value will only be available if the conditions specified in `DeleteRequest.setReturnRow(boolean)` are met.
    Returns:
      the Version

  - ### getExistingValue

    public MapValue getExistingValue()
    Returns the existing row value if available. This value will only be available if the conditions specified in `DeleteRequest.setReturnRow(boolean)` are met.
    Returns:
      the value

  - ### getExistingModificationTime

    public long getExistingModificationTime()
    Returns the existing modification time if available. This value will only be available if the conditions specified in `DeleteRequest.setReturnRow(boolean)` are met.
    Returns:
      the modification time in milliseconds since Jan 1, 1970
    Since:
      5.3.0

  - ### getReadKB

    public int getReadKB()
    Returns the read throughput consumed by this operation, in KBytes. This is the actual amount of data read by the operation. The number of read units consumed is returned by `getReadUnits()` which may be a larger number because this was an update operation.
    Returns:
      the read KBytes consumed

  - ### getWriteKB

    public int getWriteKB()
    Returns the write throughput consumed by this operation, in KBytes.
    Returns:
      the write KBytes consumed

  - ### getReadUnits

    public int getReadUnits()
    Returns the read throughput consumed by this operation, in read units. This number may be larger than that returned by `getReadKB()` because it was an update operation.
    Returns:
      the read units consumed

  - ### getWriteUnits

    public int getWriteUnits()
    Returns the write throughput consumed by this operation, in write units.
    Returns:
      the write units consumed

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`