Package org.opennebula.client.cluster
Class ClusterPool
- java.lang.Object
-
- org.opennebula.client.Pool
-
- org.opennebula.client.cluster.ClusterPool
-
-
Field Summary
Fields Modifier and Type Field Description static int
NONE_CLUSTER_ID
-
Fields inherited from class org.opennebula.client.Pool
ALL, client, elementName, GROUP, infoMethod, MINE, MINE_GROUP, poolElements, xpath
-
-
Constructor Summary
Constructors Constructor Description ClusterPool(Client client)
Creates a new cluster pool
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description PoolElement
factory(org.w3c.dom.Node node)
The factory method returns a suitable PoolElement object from an XML node.Cluster
getById(int id)
Returns the Cluster with the given Id from the pool.OneResponse
info()
Loads the xml representation of the cluster pool.static OneResponse
info(Client client)
Retrieves all the clusters in the pool.java.util.Iterator<Cluster>
iterator()
-
Methods inherited from class org.opennebula.client.Pool
getLength, info, info, info, infoAll, infoAll, infoGroup, infoGroup, infoGroupPrimary, infoMine, infoMine, item, processInfo, xmlrpcInfo
-
-
-
-
Field Detail
-
NONE_CLUSTER_ID
public static final int NONE_CLUSTER_ID
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ClusterPool
public ClusterPool(Client client)
Creates a new cluster pool- Parameters:
client
- XML-RPC Client.
-
-
Method Detail
-
factory
public PoolElement factory(org.w3c.dom.Node node)
Description copied from class:Pool
The factory method returns a suitable PoolElement object from an XML node. Each Pool must implement the corresponding factory method.
-
info
public static OneResponse info(Client client)
Retrieves all the clusters in the pool.- Parameters:
client
- XML-RPC Client.- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
info
public OneResponse info()
Loads the xml representation of the cluster pool.- Overrides:
info
in classPool
- See Also:
info(Client)
-
iterator
public java.util.Iterator<Cluster> iterator()
- Specified by:
iterator
in interfacejava.lang.Iterable<Cluster>
-
-