public class ObjectsService extends Object implements IObjectsService
| Constructor and Description |
|---|
ObjectsService(com.google.common.util.concurrent.ListeningExecutorService listeningExecutorService,
IProtobufDao protobufDao) |
| Modifier and Type | Method and Description |
|---|---|
com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Message> |
getObject(String key)
Find the object for the given tenant for the given key.
|
com.google.common.util.concurrent.ListenableFuture<List<String>> |
getObjectList(String listKey,
int start,
int count)
Get list of object keys
|
com.google.common.util.concurrent.ListenableFuture<Map<String,com.google.protobuf.Message>> |
getObjects(List<String> keysList)
Find all objects for the given set of keys.
|
com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Message> |
getPartialObject(String key,
List<String> fields)
Find an object and only return the specified fields.
|
com.google.common.util.concurrent.ListenableFuture<Map<String,com.google.protobuf.Message>> |
getPartialObjects(List<String> keys,
List<String> fields)
Get partial objects associated to the given set of keys.
|
com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Message> |
storeObject(String key,
com.google.protobuf.Message object)
Store an object with the given key.
|
com.google.common.util.concurrent.ListenableFuture<List<com.google.protobuf.Message>> |
storeObjects(Map<String,com.google.protobuf.Message> keysToObjectsMap)
Store set of objects.
|
public ObjectsService(com.google.common.util.concurrent.ListeningExecutorService listeningExecutorService,
IProtobufDao protobufDao)
public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Message> getObject(String key)
IObjectsServicegetObject in interface IObjectsServicekey - key for objectpublic com.google.common.util.concurrent.ListenableFuture<List<String>> getObjectList(String listKey, int start, int count)
IObjectsServicegetObjectList in interface IObjectsServicelistKey - key associated to the liststart - starting indexcount - number of objectspublic com.google.common.util.concurrent.ListenableFuture<Map<String,com.google.protobuf.Message>> getObjects(List<String> keysList)
IObjectsServicegetObjects in interface IObjectsServicekeysList - list of keyspublic com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Message> getPartialObject(String key, List<String> fields)
IObjectsServicegetPartialObject in interface IObjectsServicekey - object keyfields - fields to returnpublic com.google.common.util.concurrent.ListenableFuture<Map<String,com.google.protobuf.Message>> getPartialObjects(List<String> keys, List<String> fields)
IObjectsServicegetPartialObjects in interface IObjectsServicekeys - list of keysfields - list of fieldspublic com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Message> storeObject(String key, com.google.protobuf.Message object)
IObjectsServicestoreObject in interface IObjectsServicekey - the keyobject - the object to be storedpublic com.google.common.util.concurrent.ListenableFuture<List<com.google.protobuf.Message>> storeObjects(Map<String,com.google.protobuf.Message> keysToObjectsMap)
IObjectsServicestoreObjects in interface IObjectsServicekeysToObjectsMap - map of keys to objects to be storedCopyright © 2015. All rights reserved.