public class EtcdClientImpl extends java.lang.Object implements EtcdClient
| Modifier and Type | Method and Description |
|---|---|
void |
deleteKey(java.lang.String key)
Delete value for the given key.
|
java.lang.String |
getKey(java.lang.String key)
Retrieve the value of the given key, if set.
|
java.util.Map<java.lang.String,java.lang.String> |
list(java.lang.String path)
List directory at given path.
|
void |
setKey(java.lang.String key,
java.lang.String value)
Set value for the given key.
|
java.lang.String |
testAndSet(java.lang.String key,
java.lang.String oldValue,
java.lang.String newValue) |
public java.lang.String getKey(java.lang.String key)
throws EtcdException
EtcdClientgetKey in interface EtcdClientkey - Key to look upEtcdException - in case of an error (e.g. key doesn't exist)public void setKey(java.lang.String key,
java.lang.String value)
throws EtcdException
EtcdClientsetKey in interface EtcdClientkey - Key to set value forvalue - New value for the keyEtcdException - in case of an errorpublic void deleteKey(java.lang.String key)
throws EtcdException
EtcdClientdeleteKey in interface EtcdClientkey - Key to delete value forEtcdException - in case of an errorpublic java.util.Map<java.lang.String,java.lang.String> list(java.lang.String path)
throws EtcdException
EtcdClientlist in interface EtcdClientpath - Given pathEtcdException - in case of an errorpublic java.lang.String testAndSet(java.lang.String key,
java.lang.String oldValue,
java.lang.String newValue)
throws EtcdException
testAndSet in interface EtcdClientEtcdException