Package org.jclouds.providers.internal
Class BaseProviderMetadata
- java.lang.Object
-
- org.jclouds.providers.internal.BaseProviderMetadata
-
- All Implemented Interfaces:
ProviderMetadata
- Direct Known Subclasses:
AnonymousProviderMetadata
,AutoscaleUSProviderMetadata
,AutoscaleUSProviderMetadata
,AWSCloudWatchProviderMetadata
,AWSEC2ProviderMetadata
,AWSRoute53ProviderMetadata
,AWSS3ProviderMetadata
,AWSSQSProviderMetadata
,AWSSTSProviderMetadata
,AzureBlobProviderMetadata
,AzureComputeProviderMetadata
,B2ProviderMetadata
,CloudBlockStorageUKProviderMetadata
,CloudBlockStorageUSProviderMetadata
,CloudDatabasesUKProviderMetadata
,CloudDatabasesUSProviderMetadata
,CloudDNSUKProviderMetadata
,CloudDNSUSProviderMetadata
,CloudFilesUKProviderMetadata
,CloudFilesUSProviderMetadata
,CloudLoadBalancersUKProviderMetadata
,CloudLoadBalancersUSProviderMetadata
,CloudNetworksUKProviderMetadata
,CloudNetworksUSProviderMetadata
,CloudQueuesUKProviderMetadata
,CloudQueuesUSProviderMetadata
,CloudServersUKProviderMetadata
,CloudServersUSProviderMetadata
,DigitalOcean2ProviderMetadata
,DynECTProviderMetadata
,ElasticHostsAmsterdamMetadata
,ElasticHostsBlueSquareLondonProviderMetadata
,ElasticHostsDallasMetadata
,ElasticHostsHongKongProviderMetadata
,ElasticHostsMiamiMetadata
,ElasticHostsPeer1LondonProviderMetadata
,ElasticHostsPeer1LosAngelesProviderMetadata
,ElasticHostsPeer1SanAntonioProviderMetadata
,ElasticHostsPeer1TorontoProviderMetadata
,ElasticHostsSanJoseProviderMetadata
,ElasticHostsSydneyProviderMetadata
,GleSYSProviderMetadata
,Go2CloudJohannesburg1ProviderMetadata
,GoGridProviderMetadata
,GoogleCloudStorageProviderMetadata
,GoogleComputeEngineProviderMetadata
,OpenHostingEast1ProviderMetadata
,PacketProviderMetadata
,ProfitBricksProviderMetadata
,ServerloveManchesterProviderMetadata
,SkaliCloudMalaysiaProviderMetadata
,SoftLayerProviderMetadata
,UltraDNSWSProviderMetadata
public abstract class BaseProviderMetadata extends Object implements ProviderMetadata
The BaseProviderMetadata class is an abstraction ofProviderMetadata
to be extended by those implementing ProviderMetadata. (Note: This class must be abstract to allowServiceLoader
to work properly.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BaseProviderMetadata.Builder
-
Field Summary
Fields Modifier and Type Field Description protected ApiMetadata
api
protected com.google.common.base.Optional<URI>
console
protected Properties
defaultProperties
protected String
endpoint
protected com.google.common.base.Optional<URI>
homepage
protected String
id
protected Set<String>
iso3166Codes
protected Set<String>
linkedServices
protected String
name
-
Constructor Summary
Constructors Constructor Description BaseProviderMetadata(String id, String name, ApiMetadata api, String endpoint, Properties defaultProperties, com.google.common.base.Optional<URI> homepage, com.google.common.base.Optional<URI> console, Set<String> linkedServices, Set<String> iso3166Codes)
BaseProviderMetadata(BaseProviderMetadata.Builder builder)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
ApiMetadata
getApiMetadata()
com.google.common.base.Optional<URI>
getConsole()
Properties
getDefaultProperties()
Configuration Properties used when creating connections to this provider.String
getEndpoint()
com.google.common.base.Optional<URI>
getHomepage()
String
getId()
Set<String>
getIso3166Codes()
iso 3166 codes; ex.Set<String>
getLinkedServices()
String
getName()
int
hashCode()
com.google.common.base.MoreObjects.ToStringHelper
string()
ProviderMetadata.Builder
toBuilder()
String
toString()
-
-
-
Field Detail
-
id
protected final String id
-
name
protected final String name
-
api
protected final ApiMetadata api
-
endpoint
protected final String endpoint
-
defaultProperties
protected final Properties defaultProperties
-
homepage
protected final com.google.common.base.Optional<URI> homepage
-
console
protected final com.google.common.base.Optional<URI> console
-
-
Constructor Detail
-
BaseProviderMetadata
public BaseProviderMetadata(BaseProviderMetadata.Builder builder)
-
-
Method Detail
-
toBuilder
public ProviderMetadata.Builder toBuilder()
- Specified by:
toBuilder
in interfaceProviderMetadata
- See Also:
ProviderMetadata.Builder
-
string
public com.google.common.base.MoreObjects.ToStringHelper string()
-
getId
public String getId()
- Specified by:
getId
in interfaceProviderMetadata
- Returns:
- the provider's unique identifier (ex. aws-ec2, rackspace-cloudservers-us)
-
getName
public String getName()
- Specified by:
getName
in interfaceProviderMetadata
- Returns:
- the name (display name) of the provider (ex. GoGrid)
-
getApiMetadata
public ApiMetadata getApiMetadata()
- Specified by:
getApiMetadata
in interfaceProviderMetadata
- Returns:
- the provider's api
-
getEndpoint
public String getEndpoint()
- Specified by:
getEndpoint
in interfaceProviderMetadata
- Returns:
- the url for the provider's api
- See Also:
ApiMetadata#getEndpoint
-
getConsole
public com.google.common.base.Optional<URI> getConsole()
- Specified by:
getConsole
in interfaceProviderMetadata
- Returns:
- the url for the provider's console, or absent if one doesn't exist
-
getDefaultProperties
public Properties getDefaultProperties()
Configuration Properties used when creating connections to this provider. For example, location information, or default networking configuration.- Specified by:
getDefaultProperties
in interfaceProviderMetadata
- Returns:
- properties used to create connections to this provider
- See Also:
ApiMetadata.getDefaultProperties()
-
getHomepage
public com.google.common.base.Optional<URI> getHomepage()
- Specified by:
getHomepage
in interfaceProviderMetadata
- Returns:
- the url for the provider's homepage, or absent if unknown
-
getLinkedServices
public Set<String> getLinkedServices()
- Specified by:
getLinkedServices
in interfaceProviderMetadata
- Returns:
- ids of all known
providers
which have the same account as this.
-
getIso3166Codes
public Set<String> getIso3166Codes()
iso 3166 codes; ex. US-CA,US- Specified by:
getIso3166Codes
in interfaceProviderMetadata
- Returns:
- all known region/location ISO 3166 codes
-
-