Package org.ovirt.engine.sdk4.services
Interface TemplatesService
-
- All Superinterfaces:
Service
- All Known Implementing Classes:
TemplatesServiceImpl
public interface TemplatesService extends Service
This service manages the virtual machine templates available in the system.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
TemplatesService.AddFromConfigurationRequest
Add a virtual machine template to the system from a configuration.static interface
TemplatesService.AddFromConfigurationResponse
Add a virtual machine template to the system from a configuration.static interface
TemplatesService.AddFromVmRequest
Add a virtual machine template to the system from an existing virtual machine.static interface
TemplatesService.AddFromVmResponse
Add a virtual machine template to the system from an existing virtual machine.static interface
TemplatesService.AddFromVmSnapshotRequest
Add a virtual machine template to the system from a snapshot.static interface
TemplatesService.AddFromVmSnapshotResponse
Add a virtual machine template to the system from a snapshot.static interface
TemplatesService.AddRequest
Creates a new template.static interface
TemplatesService.AddResponse
Creates a new template.static interface
TemplatesService.ListRequest
Returns the list of virtual machine templates.static interface
TemplatesService.ListResponse
Returns the list of virtual machine templates.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TemplatesService.AddRequest
add()
Creates a new template.TemplatesService.AddFromConfigurationRequest
addFromConfiguration()
Add a virtual machine template to the system from a configuration.TemplatesService.AddFromVmRequest
addFromVm()
Add a virtual machine template to the system from an existing virtual machine.TemplatesService.AddFromVmSnapshotRequest
addFromVmSnapshot()
Add a virtual machine template to the system from a snapshot.TemplatesService.ListRequest
list()
Returns the list of virtual machine templates.Service
service(String path)
Service locator method, returns individual service on which the URI is dispatched.TemplateService
templateService(String id)
Returns a reference to the service that manages a specific virtual machine template.
-
-
-
Method Detail
-
add
TemplatesService.AddRequest add()
Creates a new template. This requires the `name` and `vm` elements. To identify the virtual machine use the `vm.id` or `vm.name` attributes. For example, to create a template from a virtual machine with the identifier `123` send a request like this: [source] ---- POST /ovirt-engine/api/templates ---- With a request body like this: [source,xml] ----mytemplate ---- Since version 4.3, in order to create virtual machine template from a snapshot send a request body like this: [source,xml] ---- mytemplate > and make it < >, send a request body like this: [source,xml] ---- mytemplate mydisk cow true mytemplate mytemplate_001 mytemplate cow true mytemplate cow true
-
addFromConfiguration
TemplatesService.AddFromConfigurationRequest addFromConfiguration()
Add a virtual machine template to the system from a configuration. Requires the configuration type, the configuration data, and the target cluster.
-
addFromVm
TemplatesService.AddFromVmRequest addFromVm()
Add a virtual machine template to the system from an existing virtual machine.
-
addFromVmSnapshot
TemplatesService.AddFromVmSnapshotRequest addFromVmSnapshot()
Add a virtual machine template to the system from a snapshot.
-
list
TemplatesService.ListRequest list()
Returns the list of virtual machine templates. For example: [source] ---- GET /ovirt-engine/api/templates ---- Will return the list of virtual machines and virtual machine templates. The order of the returned list of templates is not guaranteed.
-
templateService
TemplateService templateService(String id)
Returns a reference to the service that manages a specific virtual machine template.
-
-