public class VCloudRestClientModule extends RestClientModule<VCloudClient,VCloudAsyncClient>
Modifier and Type | Class and Description |
---|---|
static class |
VCloudRestClientModule.OrgCatalogItemSupplier |
static class |
VCloudRestClientModule.OrgCatalogSupplier |
static class |
VCloudRestClientModule.OrgMapSupplier |
static class |
VCloudRestClientModule.OrgVDCSupplier |
static class |
VCloudRestClientModule.URItoVDC |
Modifier and Type | Field and Description |
---|---|
static Map<Class<?>,Class<?>> |
DELEGATE_MAP |
asyncClientType, authException, delegates, syncClientType, URI_SUPPLIER_TYPE
Constructor and Description |
---|
VCloudRestClientModule() |
Modifier and Type | Method and Description |
---|---|
protected void |
bindCacheLoaders() |
protected void |
bindErrorHandlers()
overrides this to change the default error handlers for the http engine
ex.
|
protected void |
configure() |
protected FenceMode |
defaultFenceMode(String fenceMode) |
protected com.google.common.cache.LoadingCache<URI,Envelope> |
envelopes(com.google.common.cache.CacheLoader<URI,Envelope> envelopes) |
protected void |
installDefaultVCloudEndpointsModule() |
protected void |
installLocations() |
protected com.google.common.base.Supplier<URI> |
provideAuthenticationURI(VCloudVersionsClient versionService,
String version) |
protected com.google.common.base.Supplier<Org> |
provideOrg(com.google.common.base.Supplier<Map<String,Org>> orgSupplier,
com.google.common.base.Supplier<ReferenceType> defaultOrg) |
protected com.google.common.base.Supplier<Map<String,Map<String,Catalog>>> |
provideOrgCatalogItemMapSupplierCache(long seconds,
AtomicReference<AuthorizationException> authException,
VCloudRestClientModule.OrgCatalogSupplier supplier) |
protected com.google.common.base.Supplier<Map<String,Map<String,Map<String,CatalogItem>>>> |
provideOrgCatalogItemSupplierCache(long seconds,
AtomicReference<AuthorizationException> authException,
VCloudRestClientModule.OrgCatalogItemSupplier supplier) |
protected com.google.common.base.Supplier<URI> |
provideOrgListURI(com.google.common.base.Supplier<VCloudSession> sessionSupplier) |
protected com.google.common.base.Supplier<Map<String,Org>> |
provideOrgMapCache(long seconds,
AtomicReference<AuthorizationException> authException,
VCloudRestClientModule.OrgMapSupplier supplier) |
protected com.google.common.base.Supplier<Map<String,Map<String,VDC>>> |
provideOrgVDCSupplierCache(long seconds,
AtomicReference<AuthorizationException> authException,
VCloudRestClientModule.OrgVDCSupplier supplier) |
protected com.google.common.base.Supplier<Map<URI,VDC>> |
provideURIToVDC(long seconds,
AtomicReference<AuthorizationException> authException,
VCloudRestClientModule.URItoVDC supplier) |
protected com.google.common.base.Supplier<VCloudSession> |
provideVCloudTokenCache(long seconds,
AtomicReference<AuthorizationException> authException,
VCloudLoginClient login) |
protected com.google.common.base.Supplier<Map<String,ReferenceType>> |
provideVDCtoORG(long seconds,
AtomicReference<AuthorizationException> authException,
org.jclouds.vcloud.config.VCloudRestClientModule.OrgNameToOrgSupplier supplier) |
protected com.google.common.base.Supplier<Map<String,String>> |
provideVDCtoORG(com.google.common.base.Supplier<Map<String,Org>> orgNameToOrgSuppier) |
protected com.google.common.base.Predicate<URI> |
successTester(com.google.inject.Injector injector,
long completed) |
protected com.google.common.cache.LoadingCache<URI,VAppTemplate> |
vAppTemplates(com.google.common.cache.CacheLoader<URI,VAppTemplate> vAppTemplates) |
bindAsyncClient, bindClient, bindRetryHandlers
addError, addError, addError, bind, bind, bind, bindConstant, binder, bindInterceptor, bindListener, bindScope, configure, convertToTypes, currentStage, getMembersInjector, getMembersInjector, getProvider, getProvider, install, requestInjection, requestStaticInjection, requireBinding, requireBinding
@Provides @Singleton protected com.google.common.base.Supplier<VCloudSession> provideVCloudTokenCache(@Named(value="jclouds.session-interval") long seconds, AtomicReference<AuthorizationException> authException, VCloudLoginClient login)
protected void configure()
configure
in class RestClientModule<VCloudClient,VCloudAsyncClient>
protected void bindCacheLoaders()
@Provides @Singleton protected com.google.common.base.Supplier<Map<String,String>> provideVDCtoORG(com.google.common.base.Supplier<Map<String,Org>> orgNameToOrgSuppier)
@Provides @Singleton protected com.google.common.base.Supplier<Map<String,Org>> provideOrgMapCache(@Named(value="jclouds.session-interval") long seconds, AtomicReference<AuthorizationException> authException, VCloudRestClientModule.OrgMapSupplier supplier)
@Provides @Singleton protected com.google.common.base.Supplier<URI> provideOrgListURI(com.google.common.base.Supplier<VCloudSession> sessionSupplier)
protected void installDefaultVCloudEndpointsModule()
@Provides @Singleton protected com.google.common.base.Supplier<Map<String,ReferenceType>> provideVDCtoORG(@Named(value="jclouds.session-interval") long seconds, AtomicReference<AuthorizationException> authException, org.jclouds.vcloud.config.VCloudRestClientModule.OrgNameToOrgSupplier supplier)
@Provides @Singleton protected com.google.common.base.Supplier<Map<URI,VDC>> provideURIToVDC(@Named(value="jclouds.session-interval") long seconds, AtomicReference<AuthorizationException> authException, VCloudRestClientModule.URItoVDC supplier)
@Provides @Singleton protected com.google.common.base.Supplier<URI> provideAuthenticationURI(VCloudVersionsClient versionService, @Named(value="jclouds.api-version") String version)
@Provides @Singleton protected com.google.common.base.Supplier<Org> provideOrg(com.google.common.base.Supplier<Map<String,Org>> orgSupplier, com.google.common.base.Supplier<ReferenceType> defaultOrg)
@Provides @Singleton protected com.google.common.base.Predicate<URI> successTester(com.google.inject.Injector injector, @Named(value="jclouds.vcloud.timeout.task-complete") long completed)
@Provides @Singleton protected com.google.common.base.Supplier<Map<String,Map<String,Catalog>>> provideOrgCatalogItemMapSupplierCache(@Named(value="jclouds.session-interval") long seconds, AtomicReference<AuthorizationException> authException, VCloudRestClientModule.OrgCatalogSupplier supplier)
@Provides @Singleton protected com.google.common.base.Supplier<Map<String,Map<String,VDC>>> provideOrgVDCSupplierCache(@Named(value="jclouds.session-interval") long seconds, AtomicReference<AuthorizationException> authException, VCloudRestClientModule.OrgVDCSupplier supplier)
@Provides @Singleton protected com.google.common.base.Supplier<Map<String,Map<String,Map<String,CatalogItem>>>> provideOrgCatalogItemSupplierCache(@Named(value="jclouds.session-interval") long seconds, AtomicReference<AuthorizationException> authException, VCloudRestClientModule.OrgCatalogItemSupplier supplier)
@Provides @Singleton protected FenceMode defaultFenceMode(@Named(value="jclouds.vcloud.defaults.fencemode") String fenceMode)
@Provides @Singleton protected com.google.common.cache.LoadingCache<URI,VAppTemplate> vAppTemplates(com.google.common.cache.CacheLoader<URI,VAppTemplate> vAppTemplates)
@Provides @Singleton protected com.google.common.cache.LoadingCache<URI,Envelope> envelopes(com.google.common.cache.CacheLoader<URI,Envelope> envelopes)
protected void bindErrorHandlers()
RestClientModule
bind(HttpErrorHandler.class).annotatedWith(Redirection.class).to( ParseAWSErrorFromXmlContent.class); bind(HttpErrorHandler.class).annotatedWith(ClientError.class).to( ParseAWSErrorFromXmlContent.class); bind(HttpErrorHandler.class).annotatedWith(ServerError.class).to( ParseAWSErrorFromXmlContent.class);
bindErrorHandlers
in class RestClientModule<VCloudClient,VCloudAsyncClient>
protected void installLocations()
installLocations
in class RestClientModule<VCloudClient,VCloudAsyncClient>
Copyright © 2009-2012 jclouds. All Rights Reserved.