@Path(value="/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/virtualMachines")
@Consumes(value="application/json")
public interface VirtualMachineApi
Modifier and Type | Method and Description |
---|---|
URI |
capture(String name,
String vhdPrefix,
String destinationContainerName)
Capture the virtual machine image
destinationContainerName: the name of the folder created under the "system" container in the storage account
Folder structure: Microsoft.Computer > Images > destinationContainerName
Within the folder, there will be 1 page blob for the osDisk vhd and 1 block blob for the vmTemplate json file
|
VirtualMachine |
createOrUpdate(String vmname,
String location,
VirtualMachineProperties properties,
Map<String,String> tags,
Plan plan) |
URI |
delete(String name) |
void |
generalize(String name) |
VirtualMachine |
get(String name) |
VirtualMachineInstance |
getInstanceDetails(String name)
Get information about the model view and instance view of a virtual machine
|
List<VirtualMachine> |
list() |
void |
restart(String name) |
void |
start(String name) |
void |
stop(String name) |
@Named(value="GetVirtualMachine") @GET @Path(value="/{name}") VirtualMachine get(@PathParam(value="name") String name)
@Named(value="GetVirtualMachineInstance") @GET @Path(value="/{name}/instanceView") VirtualMachineInstance getInstanceDetails(@PathParam(value="name") String name)
@Named(value="CreateOrUpdateVirtualMachine") @PUT @Path(value="/{vmname}") VirtualMachine createOrUpdate(@PathParam(value="vmname") String vmname, String location, VirtualMachineProperties properties, Map<String,String> tags, @Nullable Plan plan)
@Named(value="ListVirtualMachines") @GET List<VirtualMachine> list()
@Named(value="DeleteVirtualMachine") @DELETE @Path(value="/{name}") URI delete(@PathParam(value="name") String name)
@Named(value="RestartVirtualMachine") @POST @Path(value="/{name}/restart") void restart(@PathParam(value="name") String name)
@Named(value="StartVirtualMachine") @POST @Path(value="/{name}/start") void start(@PathParam(value="name") String name)
@Named(value="StopVirtualMachine") @POST @Path(value="/{name}/powerOff") void stop(@PathParam(value="name") String name)
@Named(value="generalize") @POST @Path(value="/{name}/generalize") void generalize(@PathParam(value="name") String name)
@Named(value="capture") @POST @Path(value="/{name}/capture") @Produces(value="application/json") URI capture(@PathParam(value="name") String name, String vhdPrefix, String destinationContainerName)
Copyright © 2009-2018 The Apache Software Foundation. All Rights Reserved.