public final class DeleteValue extends RiakCommand<Void,Location>
Deleting an object from Riak is a simple matter of supplying a Location
and executing the operation.
Note that this operation returns a Void type upon success. Any failure
will be thrown as an exception when calling DeleteValue synchronously or
when calling the future's get methods.
Namespace ns = new Namespace("my_type", "my_bucket");
Location loc = new Location(ns, "my_key");
DeleteValue dv = new DeleteValue.Builder(loc).build();
client.execute(dv);
All operations can called async as well.
...
RiakFuture<Void, Location> future = client.executeAsync(dv);
...
future.await();
if (future.isSuccess())
{
...
}
| Modifier and Type | Class and Description |
|---|---|
static class |
DeleteValue.Builder
Used to construct a DeleteValue command.
|
static class |
DeleteValue.Option<T> |
| Constructor and Description |
|---|
DeleteValue(DeleteValue.Builder builder) |
| Modifier and Type | Method and Description |
|---|---|
protected RiakFuture<Void,Location> |
executeAsync(RiakCluster cluster) |
executepublic DeleteValue(DeleteValue.Builder builder)
protected RiakFuture<Void,Location> executeAsync(RiakCluster cluster)
executeAsync in class RiakCommand<Void,Location>Copyright © 2015. All rights reserved.