Package org.opennebula.client.zone
Class Zone
java.lang.Object
org.opennebula.client.PoolElement
org.opennebula.client.zone.Zone
This class represents an OpenNebula zone.
It also offers static XML-RPC call wrappers.
-
Field Summary
Fields inherited from class org.opennebula.client.PoolElement
client, id, xml, xpath
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic OneResponse
Allocates a new Zone in OpenNebula.delete()
Deletes the zone from OpenNebula.static OneResponse
Deletes a zone from OpenNebula.enable
(boolean enable) Enable or disable this Zonestatic OneResponse
Enable or disable the given Zoneinfo()
Loads the xml representation of the zone.static OneResponse
Retrieves the information of the given zone.static OneResponse
Retrieves the information of the given Zone.Renames this Zonestatic OneResponse
Renames this ZoneReplaces the template contents.Replaces the template contents.static OneResponse
Replaces the template contents.
-
Constructor Details
-
Zone
Creates a new Zone representation.- Parameters:
id
- The zone id.client
- XML-RPC Client.
-
Zone
- See Also:
-
-
Method Details
-
allocate
Allocates a new Zone in OpenNebula.- Parameters:
client
- XML-RPC Client.description
- A string containing the template of the zone.- Returns:
- If successful the message contains the associated id generated for this Zone.
-
info
Retrieves the information of the given zone.- Parameters:
client
- XML-RPC Client.id
- The zone id.- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
info
Retrieves the information of the given Zone.- Parameters:
client
- XML-RPC Client.id
- The Zone id for the Zone to retrieve the information fromdecrypt
- If true decrypt sensitive attributes- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
delete
Deletes a zone from OpenNebula.- Parameters:
client
- XML-RPC Client.id
- The zone id.- Returns:
- A encapsulated response.
-
enable
Enable or disable the given Zone- Parameters:
client
- XML-RPC Client.id
- The zone id.enable
- True for enabling, false for disabling- Returns:
- A encapsulated response.
-
update
Replaces the template contents.- Parameters:
client
- XML-RPC Client.id
- The zone id of the target zone we want to modify.new_template
- New template contentsappend
- True to append new attributes instead of replace the whole template- Returns:
- If successful the message contains the zone id.
-
rename
Renames this Zone- Parameters:
client
- XML-RPC Client.id
- The Zone id of the target Zone.name
- New name for the Zone.- Returns:
- If an error occurs the error message contains the reason.
-
info
Loads the xml representation of the zone. The info is also stored internally.- See Also:
-
delete
Deletes the zone from OpenNebula.- See Also:
-
enable
Enable or disable this Zone- Parameters:
enable
- True for enabling, false for disabling- Returns:
- A encapsulated response.
-
rename
Renames this Zone- Parameters:
name
- New name for the Zone.- Returns:
- If an error occurs the error message contains the reason.
-
update
Replaces the template contents.- Parameters:
new_template
- New template contents- Returns:
- If successful the message contains the zone id.
-
update
Replaces the template contents.- Parameters:
new_template
- New template contentsappend
- True to append new attributes instead of replace the whole template- Returns:
- If successful the message contains the zone id.
-