public class MongoDBRepoProvider
extends java.lang.Object
| Constructor and Description |
|---|
MongoDBRepoProvider() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
contain(java.lang.String groupId, java.lang.String id)
Contains the temporary resource object
|
void |
destroy()
Destroy the warehouse
|
java.lang.Object |
get(java.lang.String groupId, java.lang.String cacheId)
Gets the temporary resource object
|
java.util.List<java.lang.String> |
getAllStatusKeys(java.lang.String groupId)
Gets the key-value list of all temporary resources
|
java.util.List<java.lang.String> |
getAllStatusKeys(java.lang.String groupId, int startIndex, int toIndex)
Get the key-value list of the temporary resources from the start index to the end index
|
java.util.Map<java.lang.String,java.lang.Object> |
getAllStatusObject(java.lang.String groupId)
Gets all the mapping of temporary resources in the specified group
|
java.util.Map<java.lang.String,java.lang.Object> |
getAllStatusObject(java.lang.String groupId, int startIndex, int toIndex)
Get the temporary resources mapping table from the start index to the end index in the specified group name
|
boolean |
init(RepositorySetting setting)
Initialize the temporary storage settings
|
boolean |
remove(java.lang.String groupId, java.lang.String cacheId)
Deletes the temporary resource object
|
boolean |
save(java.lang.String groupId, java.lang.String cacheId, java.lang.Object obj, int holdTime)
Store the temporary resource
|
boolean |
update(java.lang.String groupId, java.lang.String cacheId, java.lang.Object toUpdated)
Update the specified temporary resource cache object in the set
|
public boolean init(RepositorySetting setting)
Initialize the temporary storage settings
setting - The settings of temporary storage
public java.lang.Object get(java.lang.String groupId,
java.lang.String cacheId)
Gets the temporary resource object
groupId - group idcacheId - cache idpublic java.util.List<java.lang.String> getAllStatusKeys(java.lang.String groupId)
Gets the key-value list of all temporary resources
groupId -
public java.util.List<java.lang.String> getAllStatusKeys(java.lang.String groupId,
int startIndex,
int toIndex)
Get the key-value list of the temporary resources from the start index to the end index
groupId -startIndex - starts indexingstartIndex - ends indexingpublic java.util.Map<java.lang.String,java.lang.Object> getAllStatusObject(java.lang.String groupId)
Gets all the mapping of temporary resources in the specified group
groupId -
public java.util.Map<java.lang.String,java.lang.Object> getAllStatusObject(java.lang.String groupId,
int startIndex,
int toIndex)
Get the temporary resources mapping table from the start index to the end index in the specified group name
groupId - group name idstartIndex - starts indexingstartIndex - ends indexing
public boolean contain(java.lang.String groupId,
java.lang.String id)
Contains the temporary resource object
groupId -id -
public boolean save(java.lang.String groupId,
java.lang.String cacheId,
java.lang.Object obj,
int holdTime)
Store the temporary resource
groupId - group name idcacheId - cache idobj - Temporary resource objectholdTime - Saving time. The unit is the second
public boolean update(java.lang.String groupId,
java.lang.String cacheId,
java.lang.Object toUpdated)
Update the specified temporary resource cache object in the set
groupId -cacheId -toUpdated -
public boolean remove(java.lang.String groupId,
java.lang.String cacheId)
Deletes the temporary resource object
groupId -cacheId -public void destroy()
Destroy the warehouse