org.jclouds.compute.internal
Class ComputeServiceContextImpl<S,A>

java.lang.Object
  extended by org.jclouds.compute.internal.ComputeServiceContextImpl<S,A>
All Implemented Interfaces:
ComputeServiceContext

@Singleton
public class ComputeServiceContextImpl<S,A>
extends Object
implements ComputeServiceContext

Author:
Adrian Cole

Constructor Summary
ComputeServiceContextImpl(ComputeService computeService, Map<String,Credentials> credentialStore, Utils utils, RestContext providerSpecificContext)
           
 
Method Summary
 void close()
           
 Map<String,Credentials> credentialStore()
           
 boolean equals(Object obj)
           
 ComputeService getComputeService()
           
 Map<String,Credentials> getCredentialStore()
          retrieves a list of credentials for resources created within this context, keyed on id of the resource with a namespace prefix (ex.
<S,A> RestContext<S,A>
getProviderSpecificContext()
           
 Utils getUtils()
           
 int hashCode()
           
 String toString()
           
 Utils utils()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ComputeServiceContextImpl

@Inject
public ComputeServiceContextImpl(ComputeService computeService,
                                        Map<String,Credentials> credentialStore,
                                        Utils utils,
                                        RestContext providerSpecificContext)
Method Detail

getComputeService

public ComputeService getComputeService()
Specified by:
getComputeService in interface ComputeServiceContext

getProviderSpecificContext

public <S,A> RestContext<S,A> getProviderSpecificContext()
Specified by:
getProviderSpecificContext in interface ComputeServiceContext

close

public void close()
Specified by:
close in interface ComputeServiceContext

getUtils

public Utils getUtils()
Specified by:
getUtils in interface ComputeServiceContext

utils

public Utils utils()
Specified by:
utils in interface ComputeServiceContext
See Also:
ComputeServiceContext.getUtils()

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

getCredentialStore

public Map<String,Credentials> getCredentialStore()
Description copied from interface: ComputeServiceContext
retrieves a list of credentials for resources created within this context, keyed on id of the resource with a namespace prefix (ex. node#. We are testing this approach for resources such as compute nodes, where you could access this externally.

accessing credentials for a node

the key is in the form node#id.

Specified by:
getCredentialStore in interface ComputeServiceContext

credentialStore

public Map<String,Credentials> credentialStore()
Specified by:
credentialStore in interface ComputeServiceContext
See Also:
ComputeServiceContext.getCredentialStore()


Copyright © 2009-2011 jclouds. All Rights Reserved.