add missing action

This commit is contained in:
danikov 2012-02-14 13:33:35 +00:00
parent b01a888835
commit e0361ef1a1
2 changed files with 21 additions and 0 deletions

View File

@ -29,6 +29,7 @@ import org.jclouds.rest.annotations.ExceptionParser;
import org.jclouds.rest.annotations.JAXBResponseParser;
import org.jclouds.rest.annotations.PayloadParam;
import org.jclouds.rest.annotations.RequestFilters;
import org.jclouds.vcloud.director.v1_5.domain.CaptureVAppParams;
import org.jclouds.vcloud.director.v1_5.domain.CloneMediaParams;
import org.jclouds.vcloud.director.v1_5.domain.CloneVAppParams;
import org.jclouds.vcloud.director.v1_5.domain.CloneVAppTemplateParams;
@ -64,6 +65,17 @@ public interface VdcAsyncClient {
@ExceptionParser(ThrowVCloudErrorOn4xx.class)
ListenableFuture<Vdc> getVdc(@EndpointParam(parser = ReferenceToEndpoint.class) Reference vdcRef);
/**
* @see VdcClient#captureVApp(Reference, CaptureVAppParams)
*/
@POST
@Path("/action/captureVApp")
@Consumes
@JAXBResponseParser
@ExceptionParser(ThrowVCloudErrorOn4xx.class)
ListenableFuture<Media> captureVApp(@EndpointParam(parser = ReferenceToEndpoint.class) Reference vdcRef,
@PayloadParam(value = "?") CaptureVAppParams params);
/**
* @see VdcClient#cloneMedia(Reference, CloneMediaParams)
*/

View File

@ -65,6 +65,15 @@ public interface VdcClient {
*/
Vdc getVdc(Reference vdcRef);
/**
* Captures a vApp into vApp template.
* The status of vApp template will be in UNRESOLVED(0) until the capture task is finished.
*
* @return a VApp resource which will contain a task.
* The user should should wait for this task to finish to be able to use the vApp.
*/
VAppTemplate captureVApp(Reference vdcRef, CloneMediaParams params);
/**
* Clones a media into new one.
* The status of the returned media is UNRESOLVED(0) until the task for cloning finish.