mirror of https://github.com/apache/jclouds.git
Prevent instantiation of utility classes
Also prevent extension.
This commit is contained in:
parent
967f55c2e4
commit
480f0e883d
|
@ -21,7 +21,7 @@ package org.jclouds.atmos.reference;
|
|||
*
|
||||
* @see <a href="https://community.emc.com/community/labs/atmos_online" />
|
||||
*/
|
||||
public interface AtmosHeaders {
|
||||
public final class AtmosHeaders {
|
||||
|
||||
public static final String SIGNATURE = "x-emc-signature";
|
||||
public static final String LISTABLE_META = "x-emc-listable-meta";
|
||||
|
@ -35,4 +35,7 @@ public interface AtmosHeaders {
|
|||
public static final String TOKEN = "x-emc-token";
|
||||
public static final String CHECKSUM = "x-emc-wschecksum";
|
||||
|
||||
private AtmosHeaders() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ package org.jclouds.cloudstack.config;
|
|||
/**
|
||||
* Configuration properties and constants used in CloudStack connections.
|
||||
*/
|
||||
public interface CloudStackProperties {
|
||||
public final class CloudStackProperties {
|
||||
|
||||
/**
|
||||
* Type of credentials specified during {@link ComputeServiceContextBuilder#overrides}. If
|
||||
|
@ -45,4 +45,8 @@ public interface CloudStackProperties {
|
|||
* delete the keypair(s) when the last node in the group is destroyed.
|
||||
*/
|
||||
public static final String AUTO_GENERATE_KEYPAIRS = "jclouds.cloudstack.auto-generate-keypairs";
|
||||
|
||||
private CloudStackProperties() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@ package org.jclouds.cloudwatch.domain;
|
|||
*
|
||||
* @see <a href="http://docs.amazonwebservices.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html#aws-namespaces" />
|
||||
*/
|
||||
public interface Namespaces {
|
||||
public final class Namespaces {
|
||||
|
||||
public static final String AUTO_SCALING = "AWS/AutoScaling";
|
||||
public static final String DYNAMODB = "AWS/DynamoDB";
|
||||
|
@ -34,4 +34,7 @@ public interface Namespaces {
|
|||
public static final String SQS = "AWS/SQS";
|
||||
public static final String STORAGE_GATEWAY = "AWS/StorageGateway";
|
||||
|
||||
private Namespaces() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -37,7 +37,7 @@ public class Tag {
|
|||
/**
|
||||
* Describes the well-known resource types that can be tagged.
|
||||
*/
|
||||
public interface ResourceType {
|
||||
public static final class ResourceType {
|
||||
public static final String CUSTOMER_GATEWAY = "customer-gateway";
|
||||
public static final String DHCP_OPTIONS = "dhcp-options";
|
||||
public static final String IMAGE = "image";
|
||||
|
@ -54,6 +54,10 @@ public class Tag {
|
|||
public static final String VPC = "vpc";
|
||||
public static final String VPN_CONNECTION = "vpn-connection";
|
||||
public static final String VPN_GATEWAY = "vpn-gateway";
|
||||
|
||||
private ResourceType() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
||||
public static Builder builder() {
|
||||
|
|
|
@ -19,7 +19,7 @@ package org.jclouds.openstack.keystone.v2_0.config;
|
|||
/**
|
||||
* Configuration properties and constants used in Keystone connections.
|
||||
*/
|
||||
public interface KeystoneProperties {
|
||||
public final class KeystoneProperties {
|
||||
|
||||
/**
|
||||
* Type of credentials used to log into the auth service.
|
||||
|
@ -68,4 +68,8 @@ public interface KeystoneProperties {
|
|||
* @see ServiceType
|
||||
*/
|
||||
public static final String SERVICE_TYPE = "jclouds.keystone.service-type";
|
||||
|
||||
private KeystoneProperties() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,9 +21,13 @@ package org.jclouds.openstack.keystone.v2_0.extensions;
|
|||
*
|
||||
* @see <a href= "http://docs.openstack.org/developer/keystone/extension_development.html" />
|
||||
*/
|
||||
public interface ExtensionNamespaces {
|
||||
public final class ExtensionNamespaces {
|
||||
/**
|
||||
* OpenStack Keystone Admin Support
|
||||
*/
|
||||
public static final String OS_KSADM = "http://docs.openstack.org/identity/api/ext/OS-KSADM/v1.0";
|
||||
|
||||
private ExtensionNamespaces() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,10 +16,13 @@
|
|||
*/
|
||||
package org.jclouds.openstack.v2_0.reference;
|
||||
|
||||
public interface AuthHeaders {
|
||||
public final class AuthHeaders {
|
||||
|
||||
public static final String AUTH_USER = "X-Auth-User";
|
||||
public static final String AUTH_KEY = "X-Auth-Key";
|
||||
public static final String AUTH_TOKEN = "X-Auth-Token";
|
||||
|
||||
private AuthHeaders() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@ package org.jclouds.openstack.nova.v2_0.extensions;
|
|||
*
|
||||
* @see <a href= "http://nova.openstack.org/api_ext/" />
|
||||
*/
|
||||
public interface ExtensionNamespaces {
|
||||
public final class ExtensionNamespaces {
|
||||
/**
|
||||
* Keypair Support
|
||||
*/
|
||||
|
@ -110,4 +110,8 @@ public interface ExtensionNamespaces {
|
|||
* Consoles extension
|
||||
*/
|
||||
public static final String CONSOLES = "http://docs.openstack.org/compute/ext/os-consoles/api/v2";
|
||||
|
||||
private ExtensionNamespaces() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -247,12 +247,16 @@ public class AccessControlList {
|
|||
// Class and Enum declarations to represent Grants, Grantees and Permissions //
|
||||
// /////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
public interface Permission {
|
||||
public static final class Permission {
|
||||
public static final String READ = "READ";
|
||||
public static final String WRITE = "WRITE";
|
||||
public static final String READ_ACP = "READ_ACP";
|
||||
public static final String WRITE_ACP = "WRITE_ACP";
|
||||
public static final String FULL_CONTROL = "FULL_CONTROL";
|
||||
|
||||
private Permission() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
};
|
||||
|
||||
public static class Grant implements Comparable<Grant> {
|
||||
|
@ -417,11 +421,15 @@ public class AccessControlList {
|
|||
}
|
||||
}
|
||||
|
||||
public interface GroupGranteeURI {
|
||||
public static final class GroupGranteeURI {
|
||||
public static final URI ALL_USERS = URI.create("http://acs.amazonaws.com/groups/global/AllUsers");
|
||||
public static final URI AUTHENTICATED_USERS = URI
|
||||
.create("http://acs.amazonaws.com/groups/global/AuthenticatedUsers");
|
||||
public static final URI LOG_DELIVERY = URI.create("http://acs.amazonaws.com/groups/s3/LogDelivery");
|
||||
|
||||
private GroupGranteeURI() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
||||
public static class GroupGrantee extends Grantee {
|
||||
|
|
|
@ -23,7 +23,7 @@ package org.jclouds.s3.reference;
|
|||
* href="http://docs.amazonwebservices.com/AmazonS3/latest/index.html?RESTAuthentication.html"
|
||||
* />
|
||||
*/
|
||||
public interface S3Headers {
|
||||
public final class S3Headers {
|
||||
|
||||
/**
|
||||
* Amazon S3 has clones, which often replace this with their particular tag.
|
||||
|
@ -126,4 +126,8 @@ public interface S3Headers {
|
|||
* Instruction file header to be placed in the metadata of instruction files
|
||||
*/
|
||||
public static final String CRYPTO_INSTRUCTION_FILE = HEADER_PREFIX + "crypto-instr-file";
|
||||
|
||||
private S3Headers() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ package org.jclouds.sqs.config;
|
|||
/**
|
||||
* Configuration properties and constants used in SQS connections.
|
||||
*/
|
||||
public interface SQSProperties {
|
||||
public final class SQSProperties {
|
||||
|
||||
/**
|
||||
* Integer property.
|
||||
|
@ -41,4 +41,7 @@ public interface SQSProperties {
|
|||
*/
|
||||
public static final String CREATE_QUEUE_RETRY_INTERVAL = "jclouds.sqs.create-queue.retry-interval";
|
||||
|
||||
private SQSProperties() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -24,7 +24,7 @@ package org.jclouds.sqs.domain;
|
|||
* "http://docs.amazonwebservices.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/acp-overview.html#PermissionTypes"
|
||||
* />
|
||||
*/
|
||||
public interface Attribute {
|
||||
public final class Attribute {
|
||||
|
||||
/**
|
||||
* approximate number of visible messages in a queue.
|
||||
|
@ -82,4 +82,8 @@ public interface Attribute {
|
|||
* delayed.
|
||||
*/
|
||||
public static final String DELAY_SECONDS = "DelaySeconds";
|
||||
|
||||
private Attribute() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,7 +22,7 @@ package org.jclouds.sqs.reference;
|
|||
* @see <a href="http://docs.amazonwebservices.com/AWSSimpleQueueService/2011-10-01/APIReference/Query_QueryParams.html"
|
||||
* />
|
||||
*/
|
||||
public interface SQSParameters {
|
||||
public final class SQSParameters {
|
||||
|
||||
/**
|
||||
* The action to perform. For example: CreateQueue.
|
||||
|
@ -67,4 +67,8 @@ public interface SQSParameters {
|
|||
* For more information, see Query Request Authentication in the Amazon SQS Developer Guide.
|
||||
*/
|
||||
public static final String SIGNATURE_VERSION = "SignatureVersion";
|
||||
|
||||
private SQSParameters() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@ package org.jclouds.aws.reference;
|
|||
*
|
||||
* @see <a href="http://docs.amazonwebservices.com/AWSEC2/latest/APIReference/Query-Common-Parameters.html"/>
|
||||
*/
|
||||
public interface FormParameters {
|
||||
public final class FormParameters {
|
||||
|
||||
/**
|
||||
* Indicates the action to perform. Example: RunInstances
|
||||
|
@ -72,4 +72,8 @@ public interface FormParameters {
|
|||
*
|
||||
*/
|
||||
public static final String SIGNATURE_VERSION = "SignatureVersion";
|
||||
|
||||
private FormParameters() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,7 +23,7 @@ import javax.ws.rs.core.MediaType;
|
|||
*
|
||||
* @see MediaType
|
||||
*/
|
||||
public interface VCloudMediaType {
|
||||
public final class VCloudMediaType {
|
||||
/**
|
||||
* "application/vnd.vmware.vcloud.error+xml"
|
||||
*/
|
||||
|
@ -209,4 +209,7 @@ public interface VCloudMediaType {
|
|||
*/
|
||||
public static final MediaType RASDITEM_XML_TYPE = new MediaType("application", "vnd.vmware.vcloud.rasdItem+xml");
|
||||
|
||||
private VCloudMediaType() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,10 +21,13 @@ package org.jclouds.azure.storage.reference;
|
|||
*
|
||||
* @see <a href="http://msdn.microsoft.com/en-us/library/dd179357.aspx" />
|
||||
*/
|
||||
public interface AzureStorageHeaders {
|
||||
public final class AzureStorageHeaders {
|
||||
|
||||
public static final String USER_METADATA_PREFIX = "x-ms-meta-";
|
||||
public static final String REQUEST_ID = "x-ms-request-id";
|
||||
public static final String VERSION = "x-ms-version";
|
||||
|
||||
private AzureStorageHeaders() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@ package org.jclouds.openstack.reference;
|
|||
*
|
||||
* @see <a href="http://docs.rackspacecloud.com/servers/api/cs-devguide-latest.pdf" />
|
||||
*/
|
||||
public interface AuthHeaders {
|
||||
public final class AuthHeaders {
|
||||
|
||||
public static final String AUTH_USER = "X-Auth-User";
|
||||
public static final String AUTH_KEY = "X-Auth-Key";
|
||||
|
@ -34,4 +34,7 @@ public interface AuthHeaders {
|
|||
public static final String SERVER_MANAGEMENT_URL = "X-Server-Management" + URL_SUFFIX;
|
||||
public static final String STORAGE_URL = "X-Storage" + URL_SUFFIX;
|
||||
|
||||
private AuthHeaders() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
*/
|
||||
package org.jclouds.compute.config;
|
||||
|
||||
public interface ComputeServiceProperties {
|
||||
public final class ComputeServiceProperties {
|
||||
public static final String RESOURCENAME_PREFIX = "jclouds.compute.resourcename-prefix";
|
||||
public static final String RESOURCENAME_DELIMITER = "jclouds.compute.resourcename-delimiter";
|
||||
|
||||
|
@ -109,4 +109,7 @@ public interface ComputeServiceProperties {
|
|||
*/
|
||||
public static final String SOCKET_FINDER_ALLOWED_INTERFACES = "jclouds.compute.socket-finder-allowed-interfaces";
|
||||
|
||||
private ComputeServiceProperties() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,6 +16,10 @@
|
|||
*/
|
||||
package org.jclouds.gogrid.reference;
|
||||
|
||||
public interface GoGridHeaders {
|
||||
public final class GoGridHeaders {
|
||||
public static final String VERSION = "v";
|
||||
|
||||
private GoGridHeaders() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
*/
|
||||
package org.jclouds.gogrid.reference;
|
||||
|
||||
public interface GoGridQueryParams {
|
||||
public final class GoGridQueryParams {
|
||||
|
||||
public static final String ID_KEY = "id";
|
||||
public static final String NAME_KEY = "name";
|
||||
|
@ -60,4 +60,8 @@ public interface GoGridQueryParams {
|
|||
public static final String IMAGE_DESCRIPTION_KEY = "description";
|
||||
|
||||
public static final String LOOKUP_LIST_KEY = "lookup";
|
||||
|
||||
private GoGridQueryParams() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@ package org.jclouds.softlayer.reference;
|
|||
/**
|
||||
* Configuration properties and constants used in SoftLayer connections.
|
||||
*/
|
||||
public interface SoftLayerConstants {
|
||||
public final class SoftLayerConstants {
|
||||
|
||||
public static final String SOFTLAYER_PROVIDER_NAME = "softlayer";
|
||||
|
||||
|
@ -40,4 +40,7 @@ public interface SoftLayerConstants {
|
|||
*/
|
||||
public static final String PROPERTY_SOFTLAYER_INCLUDE_PUBLIC_IMAGES = "jclouds.softlayer.include_public_images";
|
||||
|
||||
private SoftLayerConstants() {
|
||||
throw new AssertionError("intentionally unimplemented");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue