Namespace org.wasmcloud.interface.keyvalue
returns whether the store contains the key
|
|
|
input: |
String |
|
output: |
Boolean |
|
Del(operation)
Deletes a key, returning true if the key was deleted
|
|
|
input: |
String |
|
output: |
Boolean |
|
Get(operation)
Gets a value for a specified key. If the key exists,
the return structure contains exists: true and the value,
otherwise the return structure contains exists == false.
Response to get request
|
|
|
exists: |
Boolean |
whether or not the value existed |
value: |
String |
the value, if it existed |
Increments a numeric value, returning the new value
Append a value onto the end of a list. Returns the new list size
Parameter to ListAdd operation
|
|
|
listName: |
String |
name of the list to modify |
value: |
String |
value to append to the list |
Deletes a list and its contents
input: list name
output: true if the list existed and was deleted
|
|
|
input: |
String |
|
output: |
Boolean |
|
Deletes a value from a list. Returns true if the item was removed.
Removes an item from the list. If the item occurred more than once,
removes only the first item.
Returns true if the item was found.
|
|
|
listName: |
String |
name of list to modify |
value: |
String |
|
Retrieves a range of values from a list using 0-based indices.
Start and end values are inclusive, for example, (0,10) returns
11 items if the list contains at least 11 items. If the stop value
is beyond the end of the list, it is treated as the end of the list.
Set(operation)
Sets the value of a key.
expires is an optional number of seconds before the value should be automatically deleted,
or 0 for no expiration.
Add an item into a set. Returns number of items added (1 or 0)
|
|
|
setName: |
String |
name of the set |
value: |
String |
value to add to the set |
clears all values from the set and removes it
input: set name
output: true if the set existed and was deleted
|
|
|
input: |
String |
|
output: |
Boolean |
|
Deletes an item from the set. Returns number of items removed from the set (1 or 0)
|
|
|
setName: |
String |
|
value: |
String |
|
perform intersection of sets and returns values from the intersection.
input: list of sets for performing intersection (at least two)
output: values
Retrieves all items from a set
input: String
output: set members
|
|
|
expires: |
org.wasmcloud.model#U32 |
expiration time in seconds 0 for no expiration |
key: |
String |
the key name to change (or create) |
value: |
String |
the new value |
perform union of sets and returns values from the union
input: list of sets for performing union (at least two)
output: union of values
list of strings