|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface TemplateApi
Provides synchronous access to cloudstack via their REST API.
| Method Summary | |
|---|---|
AsyncCreateResponse |
copyTemplateToZone(String id,
String sourceZoneId,
String destZoneId)
Copies a template from one zone to another. |
AsyncCreateResponse |
createTemplate(TemplateMetadata templateMetadata,
CreateTemplateOptions... options)
Creates a template of a virtual machine. |
AsyncCreateResponse |
deleteTemplate(String id,
DeleteTemplateOptions... options)
Deletes a template from the system. |
AsyncCreateResponse |
extractTemplate(String id,
ExtractMode mode,
String zoneId,
ExtractTemplateOptions... options)
|
Template |
getTemplateInZone(String templateId,
String zoneId)
get a specific template by id |
Set<TemplatePermission> |
listTemplatePermissions(String id,
AccountInDomainOptions... options)
List template visibility and all accounts that have permissions to view this template. |
Set<Template> |
listTemplates()
List all executable templates. |
Set<Template> |
listTemplates(ListTemplatesOptions options)
List all public, private, and privileged templates. |
Set<Template> |
registerTemplate(TemplateMetadata templateMetadata,
String format,
String hypervisor,
String url,
String zoneId,
RegisterTemplateOptions... options)
Registers an existing template into the Cloud.com cloud. |
Template |
updateTemplate(String id,
UpdateTemplateOptions... options)
Updates attributes of a template. |
void |
updateTemplatePermissions(String id,
UpdateTemplatePermissionsOptions... options)
Updates a template visibility permissions. |
| Method Detail |
|---|
@Named(value="createTemplate")
AsyncCreateResponse createTemplate(TemplateMetadata templateMetadata,
CreateTemplateOptions... options)
templateMetadata - overall description of the templateoptions - optional arguments
://download.cloud.com/releases/2.2.0/api_2.2.8/user/createTemplate
.html
@Named(value="registerTemplate")
Set<Template> registerTemplate(TemplateMetadata templateMetadata,
String format,
String hypervisor,
String url,
String zoneId,
RegisterTemplateOptions... options)
templateMetadata - overall description of the templateformat - the format for the template. Possible values include QCOW2, RAW,
and VHD.url - the URL of where the template is hosted. Possible URL include
http:// and https://zoneId - the ID of the zone the template is to be hosted onoptions - optional arguments
://download.cloud.com/releases/2.2.0/api_2.2.8/user/registerTemplate
.html
@Named(value="updateTemplate")
Template updateTemplate(String id,
UpdateTemplateOptions... options)
id - the ID of the image fileoptions - optional arguments
://download.cloud.com/releases/2.2.0/api_2.2.8/user/updateTemplate
.html
@Named(value="copyTemplate")
AsyncCreateResponse copyTemplateToZone(String id,
String sourceZoneId,
String destZoneId)
id - Template ID.sourceZoneId - ID of the zone the template is currently hosted on.destZoneId - ID of the zone the template is being copied to.
://download.cloud.com/releases/2.2.0/api_2.2.8/user/copyTemplate.html
@Named(value="deleteTemplate")
AsyncCreateResponse deleteTemplate(String id,
DeleteTemplateOptions... options)
id - the ID of the templateoptions - optional arguments://download.cloud.com/releases/2.2.0/api_2.2.8/user/deleteTemplate
.html@Named(value="listTemplates") Set<Template> listTemplates()
://download.cloud.com/releases/2.2.0/api_2.2.8/user/listTemplates.
html@Named(value="listTemplates") Set<Template> listTemplates(ListTemplatesOptions options)
options - if present, how to constrain the list, defaults to all
executable templates
://download.cloud.com/releases/2.2.0/api_2.2.8/user/listTemplates.
html,
TemplateFilter
@Named(value="listTemplates")
Template getTemplateInZone(String templateId,
String zoneId)
templateId - zoneId - zone template is defined in
@Named(value="updateTemplatePermissions")
void updateTemplatePermissions(String id,
UpdateTemplatePermissionsOptions... options)
id - the template IDoptions - optional argumentsupdateTemplatePermissions.html
@Named(value="listTemplatePermissions")
Set<TemplatePermission> listTemplatePermissions(String id,
AccountInDomainOptions... options)
id - the template IDoptions - optional arguments
listTemplatePermissions.html
@Named(value="extractTemplate")
AsyncCreateResponse extractTemplate(String id,
ExtractMode mode,
String zoneId,
ExtractTemplateOptions... options)
id - the ID of the templatemode - FIXME the mode of extraction - HTTP_DOWNLOAD or FTP_UPLOADzoneId - the ID of the zone where the ISO is originally locatedoptions - optional arguments
://download.cloud.com/releases/2.2.0/api_2.2.8/user/extractTemplate
.html
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||