org.dasein.cloud.google.compute.server
Class DiskSupport

java.lang.Object
  extended by org.dasein.cloud.compute.AbstractVolumeSupport
      extended by org.dasein.cloud.google.compute.server.DiskSupport
All Implemented Interfaces:
org.dasein.cloud.AccessControlledService, org.dasein.cloud.compute.VolumeSupport

public class DiskSupport
extends org.dasein.cloud.compute.AbstractVolumeSupport

Implements the volume services supported in the Google API.

Since:
2014.03
Version:
2014.03 initial version
Author:
Drew Lyall

Field Summary
 
Fields inherited from interface org.dasein.cloud.compute.VolumeSupport
ANY, ATTACH, CREATE_VOLUME, DETACH, GET_VOLUME, LIST_VOLUME, REMOVE_VOLUME
 
Constructor Summary
DiskSupport(Google provider)
           
 
Method Summary
 void attach(String volumeId, String toServer, String deviceId)
           
 String createVolume(org.dasein.cloud.compute.VolumeCreateOptions options)
           
 void detach(String volumeId, boolean force)
           
 GCEVolumeCapabilities getCapabilities()
           
 int getMaximumVolumeCount()
           
 Storage<Gigabyte> getMaximumVolumeSize()
           
 Storage<Gigabyte> getMinimumVolumeSize()
           
 String getProviderTermForVolume(Locale locale)
           
 org.dasein.cloud.compute.Volume getVolume(String volumeId)
           
 org.dasein.cloud.Requirement getVolumeProductRequirement()
           
 boolean isSubscribed()
           
 boolean isVolumeSizeDeterminedByProduct()
           
 Iterable<String> listPossibleDeviceIds(org.dasein.cloud.compute.Platform platform)
           
 Iterable<org.dasein.cloud.compute.VolumeFormat> listSupportedFormats()
           
 Iterable<org.dasein.cloud.compute.VolumeProduct> listVolumeProducts()
           
 Iterable<org.dasein.cloud.compute.Volume> listVolumes()
           
 Iterable<org.dasein.cloud.compute.Volume> listVolumes(org.dasein.cloud.compute.VolumeFilterOptions options)
           
 Iterable<org.dasein.cloud.ResourceStatus> listVolumeStatus()
           
 void remove(String volumeId)
           
 org.dasein.cloud.compute.Volume toVolume(com.google.api.services.compute.model.Disk disk)
           
 
Methods inherited from class org.dasein.cloud.compute.AbstractVolumeSupport
create, detach, getContext, getProvider, mapServiceAction, removeTags, removeTags, toString, updateTags, updateTags
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DiskSupport

public DiskSupport(Google provider)
Method Detail

attach

public void attach(@Nonnull
                   String volumeId,
                   @Nonnull
                   String toServer,
                   @Nonnull
                   String deviceId)
            throws org.dasein.cloud.InternalException,
                   org.dasein.cloud.CloudException
Specified by:
attach in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
attach in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

createVolume

@Nonnull
public String createVolume(@Nonnull
                                   org.dasein.cloud.compute.VolumeCreateOptions options)
                    throws org.dasein.cloud.InternalException,
                           org.dasein.cloud.CloudException
Specified by:
createVolume in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
createVolume in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

detach

public void detach(@Nonnull
                   String volumeId,
                   boolean force)
            throws org.dasein.cloud.InternalException,
                   org.dasein.cloud.CloudException
Specified by:
detach in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
detach in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

getCapabilities

@Nonnull
public GCEVolumeCapabilities getCapabilities()
                                      throws org.dasein.cloud.CloudException,
                                             org.dasein.cloud.InternalException
Throws:
org.dasein.cloud.CloudException
org.dasein.cloud.InternalException

getMaximumVolumeCount

public int getMaximumVolumeCount()
                          throws org.dasein.cloud.InternalException,
                                 org.dasein.cloud.CloudException
Specified by:
getMaximumVolumeCount in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
getMaximumVolumeCount in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

getMaximumVolumeSize

public Storage<Gigabyte> getMaximumVolumeSize()
                                       throws org.dasein.cloud.InternalException,
                                              org.dasein.cloud.CloudException
Specified by:
getMaximumVolumeSize in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
getMaximumVolumeSize in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

getMinimumVolumeSize

@Nonnull
public Storage<Gigabyte> getMinimumVolumeSize()
                                       throws org.dasein.cloud.InternalException,
                                              org.dasein.cloud.CloudException
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

getProviderTermForVolume

@Nonnull
public String getProviderTermForVolume(@Nonnull
                                               Locale locale)

getVolume

public org.dasein.cloud.compute.Volume getVolume(@Nonnull
                                                 String volumeId)
                                          throws org.dasein.cloud.InternalException,
                                                 org.dasein.cloud.CloudException
Specified by:
getVolume in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
getVolume in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

getVolumeProductRequirement

@Nonnull
public org.dasein.cloud.Requirement getVolumeProductRequirement()
                                                         throws org.dasein.cloud.InternalException,
                                                                org.dasein.cloud.CloudException
Specified by:
getVolumeProductRequirement in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
getVolumeProductRequirement in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

isVolumeSizeDeterminedByProduct

public boolean isVolumeSizeDeterminedByProduct()
                                        throws org.dasein.cloud.InternalException,
                                               org.dasein.cloud.CloudException
Specified by:
isVolumeSizeDeterminedByProduct in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
isVolumeSizeDeterminedByProduct in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

listPossibleDeviceIds

@Nonnull
public Iterable<String> listPossibleDeviceIds(@Nonnull
                                                      org.dasein.cloud.compute.Platform platform)
                                       throws org.dasein.cloud.InternalException,
                                              org.dasein.cloud.CloudException
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

listSupportedFormats

@Nonnull
public Iterable<org.dasein.cloud.compute.VolumeFormat> listSupportedFormats()
                                                                     throws org.dasein.cloud.InternalException,
                                                                            org.dasein.cloud.CloudException
Specified by:
listSupportedFormats in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
listSupportedFormats in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

listVolumeProducts

@Nonnull
public Iterable<org.dasein.cloud.compute.VolumeProduct> listVolumeProducts()
                                                                    throws org.dasein.cloud.InternalException,
                                                                           org.dasein.cloud.CloudException
Specified by:
listVolumeProducts in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
listVolumeProducts in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

listVolumeStatus

@Nonnull
public Iterable<org.dasein.cloud.ResourceStatus> listVolumeStatus()
                                                           throws org.dasein.cloud.InternalException,
                                                                  org.dasein.cloud.CloudException
Specified by:
listVolumeStatus in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
listVolumeStatus in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

listVolumes

@Nonnull
public Iterable<org.dasein.cloud.compute.Volume> listVolumes()
                                                      throws org.dasein.cloud.InternalException,
                                                             org.dasein.cloud.CloudException
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

listVolumes

@Nonnull
public Iterable<org.dasein.cloud.compute.Volume> listVolumes(org.dasein.cloud.compute.VolumeFilterOptions options)
                                                      throws org.dasein.cloud.InternalException,
                                                             org.dasein.cloud.CloudException
Specified by:
listVolumes in interface org.dasein.cloud.compute.VolumeSupport
Overrides:
listVolumes in class org.dasein.cloud.compute.AbstractVolumeSupport
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

isSubscribed

public boolean isSubscribed()
                     throws org.dasein.cloud.CloudException,
                            org.dasein.cloud.InternalException
Throws:
org.dasein.cloud.CloudException
org.dasein.cloud.InternalException

remove

public void remove(@Nonnull
                   String volumeId)
            throws org.dasein.cloud.InternalException,
                   org.dasein.cloud.CloudException
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException

toVolume

public org.dasein.cloud.compute.Volume toVolume(com.google.api.services.compute.model.Disk disk)
                                         throws org.dasein.cloud.InternalException,
                                                org.dasein.cloud.CloudException
Throws:
org.dasein.cloud.InternalException
org.dasein.cloud.CloudException


Copyright © 2014 Dell, Inc. All Rights Reserved.