public class ContentStoreManagerImpl extends Object implements ContentStoreManager, Securable
Constructor and Description |
---|
ContentStoreManagerImpl(String host,
String port)
Constructor for ContentStoreManagerImpl.
|
ContentStoreManagerImpl(String host,
String port,
String context)
Constructor for ContentStoreManagerImpl.
|
Modifier and Type | Method and Description |
---|---|
protected String |
getBaseURL() |
ContentStore |
getContentStore(String storeID)
Gets a specific content store based on ID.
|
ContentStore |
getContentStore(String storeID,
int maxRetries)
Gets a specific content store based on ID.
|
Map<String,ContentStore> |
getContentStores()
Gets all available content stores.
|
Map<String,ContentStore> |
getContentStores(int maxRetries)
Gets all available content stores.
|
ContentStore |
getPrimaryContentStore()
Gets the primary content store.
|
ContentStore |
getPrimaryContentStore(int maxRetries)
Gets the primary content store.
|
ContentStore |
getPrimaryContentStoreAsAnonymous()
Provides access to the primary content store without requiring login().
|
ContentStore |
getPrimaryContentStoreAsAnonymous(int maxRetries)
Provides access to the primary content store without requiring login().
|
protected RestHttpHelper |
getRestHelper() |
void |
login(Credential appCred)
This method supplies user credentials to the application.
|
void |
logout()
This method clears any previously logged-in credentials.
|
protected ContentStore |
newContentStoreImpl(StorageAccount acct) |
protected ContentStore |
newContentStoreImpl(StorageAccount acct,
int maxRetries) |
void |
reinitialize(String host,
String port,
String context)
reconfigure
|
protected void |
setRestHelper(RestHttpHelper restHelper) |
public ContentStoreManagerImpl(String host, String port)
Constructor for ContentStoreManagerImpl.
public ContentStoreManagerImpl(String host, String port, String context)
Constructor for ContentStoreManagerImpl.
host
- the host name on which DuraStore can be accessedport
- the port on which DuraStore can be accessedcontext
- the application context by which DuraStore can be accessedpublic void reinitialize(String host, String port, String context) throws ContentStoreException
ContentStoreManager
reconfigure
reinitialize
in interface ContentStoreManager
host
- of durastoreport
- of durastorecontext
- of durastoreContentStoreException
public Map<String,ContentStore> getContentStores() throws ContentStoreException
getContentStores
in interface ContentStoreManager
ContentStoreException
- if the content store list cannot be retrievedpublic Map<String,ContentStore> getContentStores(int maxRetries) throws ContentStoreException
getContentStores
in interface ContentStoreManager
maxRetries
- number of retries to perform if a content store call failsContentStoreException
- if the content store list cannot be retrievedpublic ContentStore getContentStore(String storeID) throws ContentStoreException
getContentStore
in interface ContentStoreManager
storeID
- the ID of a particular content storeContentStoreException
- if the content store cannot be retrievedpublic ContentStore getContentStore(String storeID, int maxRetries) throws ContentStoreException
getContentStore
in interface ContentStoreManager
storeID
- the ID of a particular content storemaxRetries
- number of retries to perform if a content store call failsContentStoreException
- if the content store cannot be retrievedpublic ContentStore getPrimaryContentStore() throws ContentStoreException
getPrimaryContentStore
in interface ContentStoreManager
ContentStoreException
public ContentStore getPrimaryContentStore(int maxRetries) throws ContentStoreException
getPrimaryContentStore
in interface ContentStoreManager
maxRetries
- number of retries to perform if a content store call failsContentStoreException
public ContentStore getPrimaryContentStoreAsAnonymous() throws ContentStoreException
getPrimaryContentStoreAsAnonymous
in interface ContentStoreManager
ContentStoreException
public ContentStore getPrimaryContentStoreAsAnonymous(int maxRetries) throws ContentStoreException
getPrimaryContentStoreAsAnonymous
in interface ContentStoreManager
maxRetries
- number of retries to perform if a content store call failsContentStoreException
public void login(Credential appCred)
Securable
public void logout()
Securable
protected ContentStore newContentStoreImpl(StorageAccount acct)
protected ContentStore newContentStoreImpl(StorageAccount acct, int maxRetries)
protected String getBaseURL()
protected RestHttpHelper getRestHelper()
protected void setRestHelper(RestHttpHelper restHelper)
Copyright © 2009–2014 DuraSpace. All rights reserved.