|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.wisc.trace.uch.resource.ResourceManager
public class ResourceManager
Manage Resource Sheet, Local and Resource Server Resources. Also provide methods to upload/download resources as well as get their properties.
| Constructor Summary | |
|---|---|
ResourceManager(UCH uch,
String localResDirUri,
String resServerAppPath,
String cacheDirUri)
Constructor. |
|
ResourceManager(UCH uch,
String localResDirUri,
String resServerAppPath,
String cacheDirUri,
String userName,
String password)
Constructor. |
|
| Method Summary | |
|---|---|
boolean |
addLocalResource(String ucfFileURI)
Add resource derived by specifies UCF file to the local resources. |
void |
addResourceDir(String tdUri)
Parse <ResDir> Element of Target Description and add it in the list of TargetDescriptions. |
List<String> |
clearCache()
Clear all Atomic and Resource Server Resources. |
List<String> |
clearCache(String resourceType)
Clear specified type of Resources. |
List<String> |
clearResourceSheetCache()
Clear all the Resource Sheet resources. |
List<String> |
clearUipmClientCache()
Clear all UIPM Client resources. |
String |
convertURI(String uri)
Call the same method of UCH. |
List<Map<String,Object>> |
getDynRes(String sessionId,
List<Map<String,String>> resProps)
Called on UCH for getting Dynamic Resource. |
List<List<Map<String,List<String>>>> |
getResources(String sessionId,
List<Map<String,List<String>>> resPropsList)
Get Resources from Local Resources, Resource Server, Target Adapter or Resource Sheet as par the requested resource property resourceType. |
String |
getResServerAppPath()
Get the String value of Resource Server app path. |
Map<String,List<String>> |
getResServerResource(Map<String,List<String>> resourceProps)
Retrieve only best matched Resource from Resource Server. |
String |
getUserProfile()
Get User Profile for logged user. |
boolean |
isUriContainsResServerAppPath(String uri)
Call the same method of UCH. |
String |
retrieveResource(String uri)
Retrieve the resource from Resource Server and save it in cache directory and return that file path. |
void |
updateDynRes(List<String> sessionIds,
List<String> eltIds)
Store Information about the Dynamic Resource. |
List<Map<String,String>> |
uploadResources(List<Map<String,List<String>>> props,
List<String> owners,
List<String> groups,
Map<String,List<String>> rights,
List<String> resourceUri)
Upload Specified Resources with specified Properties, Owners and Groups. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ResourceManager(UCH uch,
String localResDirUri,
String resServerAppPath,
String cacheDirUri)
uch - an Object of UCHlocalResDirUri - a String value of local resource directory URI path.resServerAppPath - a String value of Resource Server PathcacheDirUri - a String value of Cache dir path
public ResourceManager(UCH uch,
String localResDirUri,
String resServerAppPath,
String cacheDirUri,
String userName,
String password)
uch - an Object of UCHlocalResDirUri - a String value of local resource directory URI path.resServerAppPath - a String value of Resource Server PathcacheDirUri - a String value of Cache dir pathuserName - a String value of userNamepassword - a String value of password| Method Detail |
|---|
public String getResServerAppPath()
public String convertURI(String uri)
uri - a String value of URI
public boolean isUriContainsResServerAppPath(String uri)
uri - a String value of URI
public void addResourceDir(String tdUri)
tdUri - a String value of Target Description URI(tdUri)
public List<Map<String,Object>> getDynRes(String sessionId,
List<Map<String,String>> resProps)
sessionId - a String value of Session IdresProps - an Object of List<Map<String, String>>
public void updateDynRes(List<String> sessionIds,
List<String> eltIds)
sessionIds - a List<String> value of sessionIdseltIds - a List<String> value of elementIds
public List<Map<String,String>> uploadResources(List<Map<String,List<String>>> props,
List<String> owners,
List<String> groups,
Map<String,List<String>> rights,
List<String> resourceUri)
props - an Object of List<Map<String, List<String>>> specifies Resource Propertiesowners - an Object of List<String> specifies owners of Resourcegroups - an Object of List<String> specifies groups of Resourcerights - an Object of Map<String, List<String>> specifies rights of ResourceresourceUri - a String value of local resource path URI
public boolean addLocalResource(String ucfFileURI)
ucfFileURI - a String value of UCF file.
public String getUserProfile()
public List<List<Map<String,List<String>>>> getResources(String sessionId,
List<Map<String,List<String>>> resPropsList)
sessionId - a String value of SessionIdresPropsList - an Object of List<Map<String, List<String>>>
public String retrieveResource(String uri)
uri - a String value of uri.
public Map<String,List<String>> getResServerResource(Map<String,List<String>> resourceProps)
resourceProps - an Object of Map<String, String>
public List<String> clearCache()
public List<String> clearResourceSheetCache()
public List<String> clearUipmClientCache()
public List<String> clearCache(String resourceType)
resourceType - a String value of Resource Type
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||