org.javaswift.joss.command.shared.identity.access
Class AbstractAccess

java.lang.Object
  extended by org.javaswift.joss.command.shared.identity.access.AbstractAccess
All Implemented Interfaces:
Access
Direct Known Subclasses:
AccessNoTenant, AccessTenant

public abstract class AbstractAccess
extends Object
implements Access


Field Summary
 Metadata metadata
           
static String SERVICE_CATALOG_OBJECT_STORE
           
 Token token
           
 User user
           
 
Constructor Summary
AbstractAccess()
           
 
Method Summary
protected abstract  EndPoint determineCurrentEndPoint()
           
protected  EndPoint getCurrentEndPoint()
           
 String getInternalURL()
          The internal URL to access resources with.
 String getPreferredRegion()
           
 String getPublicURL()
          The public URL of a resource.
 String getToken()
          The security token to pass to all secure ObjectStore calls.
abstract  boolean isTenantSupplied()
          Ascertains whether tenant ID and/or name were supplied.
 void setPreferredRegion(String preferredRegion)
          The ObjectStore holds multiple regions.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.javaswift.joss.model.Access
getTempUrlPrefix
 

Field Detail

SERVICE_CATALOG_OBJECT_STORE

public static final String SERVICE_CATALOG_OBJECT_STORE
See Also:
Constant Field Values

token

public Token token

user

public User user

metadata

public Metadata metadata
Constructor Detail

AbstractAccess

public AbstractAccess()
Method Detail

determineCurrentEndPoint

protected abstract EndPoint determineCurrentEndPoint()

isTenantSupplied

public abstract boolean isTenantSupplied()
Description copied from interface: Access
Ascertains whether tenant ID and/or name were supplied.

Specified by:
isTenantSupplied in interface Access
Returns:
true if tenant ID and/or name were supplied before the authentication call

getToken

public String getToken()
Description copied from interface: Access
The security token to pass to all secure ObjectStore calls. Note that this token has a validity for a period of 24 hours. After that, you require a new token.

Specified by:
getToken in interface Access
Returns:
the token

getPreferredRegion

public String getPreferredRegion()

setPreferredRegion

public void setPreferredRegion(String preferredRegion)
Description copied from interface: Access
The ObjectStore holds multiple regions. If you state a preference, it will choose that region (if available). You will see the result in getting the internal or public URL.

Specified by:
setPreferredRegion in interface Access
Parameters:
preferredRegion - the region where you want to access the resources

getCurrentEndPoint

protected EndPoint getCurrentEndPoint()

getInternalURL

public String getInternalURL()
Description copied from interface: Access
The internal URL to access resources with. This works on both public and private containers.

Specified by:
getInternalURL in interface Access
Returns:
internal URL

getPublicURL

public String getPublicURL()
Description copied from interface: Access
The public URL of a resource. This is the URL you might want to display to the outside world, expect that you may replace the domain with your own.

Specified by:
getPublicURL in interface Access
Returns:
public URL


Copyright © 2012-2014 42 BV. All Rights Reserved.