Package org.opennebula.client.vmgroup
Class VMGroupPool
- java.lang.Object
-
- org.opennebula.client.Pool
-
- org.opennebula.client.vmgroup.VMGroupPool
-
-
Field Summary
-
Fields inherited from class org.opennebula.client.Pool
ALL, client, elementName, GROUP, infoMethod, MINE, MINE_GROUP, poolElements, xpath
-
-
Constructor Summary
Constructors Constructor Description VMGroupPool(Client client)
Creates a new VMGroup pool with the default filter flag value set toPool.MINE_GROUP
(VMGroups belonging to the connected user, and the ones in his group)VMGroupPool(Client client, int filter)
Creates a new VMGroup 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.VMGroup
getById(int id)
Returns the VMGroup with the given Id from the pool.OneResponse
info()
Loads the xml representation of all or part of the VMGroups in the pool.OneResponse
info(int filter, int startId, int endId)
Retrieves all or part of the VMGroups in the pool.static OneResponse
info(Client client, int filter)
Retrieves all or part of the VMGroups in the pool.static OneResponse
info(Client client, int filter, int startId, int endId)
Retrieves all or part of the VMGroups in the pool.OneResponse
infoAll()
Loads the xml representation of all the VMGroups in the pool.static OneResponse
infoAll(Client client)
Retrieves all the VMGroups in the pool.OneResponse
infoGroup()
Loads the xml representation of all the connected user's VMGroups and the ones in his group.static OneResponse
infoGroup(Client client)
Retrieves all the connected user's VMGroups and the ones in his group.OneResponse
infoMine()
Loads the xml representation of all the connected user's VMGroups.static OneResponse
infoMine(Client client)
Retrieves all the connected user's VMGroups.java.util.Iterator<VMGroup>
iterator()
-
Methods inherited from class org.opennebula.client.Pool
getLength, info, info, infoAll, infoGroup, infoGroupPrimary, infoMine, item, processInfo, xmlrpcInfo
-
-
-
-
Constructor Detail
-
VMGroupPool
public VMGroupPool(Client client)
Creates a new VMGroup pool with the default filter flag value set toPool.MINE_GROUP
(VMGroups belonging to the connected user, and the ones in his group)- Parameters:
client
- XML-RPC Client.- See Also:
VMGroupPool(Client, int)
-
VMGroupPool
public VMGroupPool(Client client, int filter)
Creates a new VMGroup pool.- Parameters:
client
- XML-RPC Client.filter
- Filter flag to use by default in the methodinfo()
. Possible values:Pool.ALL
: All VMGroupsPool.MINE
: Connected user's VMGroupsPool.MINE_GROUP
: Connected user's VMGroups, and the ones in his groupPool.GROUP
: User's primary group VMGroups- >= 0 UID User's VMGroups
-
-
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, int filter)
Retrieves all or part of the VMGroups in the pool.- Parameters:
client
- XML-RPC Client.filter
- Filter flag to use. Possible values:Pool.ALL
: All VMGroupsPool.MINE
: Connected user's VMGroupsPool.MINE_GROUP
: Connected user's VMGroups, and the ones in his groupPool.GROUP
: User's primary group VMGroups- >= 0 UID User's VMGroups
- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
infoAll
public static OneResponse infoAll(Client client)
Retrieves all the VMGroups in the pool.- Parameters:
client
- XML-RPC Client.- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
infoMine
public static OneResponse infoMine(Client client)
Retrieves all the connected user's VMGroups.- Parameters:
client
- XML-RPC Client.- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
infoGroup
public static OneResponse infoGroup(Client client)
Retrieves all the connected user's VMGroups and the ones in his group.- Parameters:
client
- XML-RPC Client.- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
info
public static OneResponse info(Client client, int filter, int startId, int endId)
Retrieves all or part of the VMGroups in the pool. The VMGroups to retrieve can be also filtered by Id, specifying the first and last Id to include.- Parameters:
client
- XML-RPC Client.filter
- Filter flag to use. Possible values:Pool.ALL
: All VMGroupsPool.MINE
: Connected user's VMGroupsPool.MINE_GROUP
: Connected user's VMGroups, and the ones in his groupPool.GROUP
: User's primary group VMGroups- >= 0 UID User's VMGroups
startId
- Lowest Id to retrieveendId
- Biggest Id to retrieve- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
info
public OneResponse info()
Loads the xml representation of all or part of the VMGroups in the pool. The filter used is the one set in the constructor.- Overrides:
info
in classPool
- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
- See Also:
info(Client, int)
-
infoAll
public OneResponse infoAll()
Loads the xml representation of all the VMGroups in the pool.
-
infoMine
public OneResponse infoMine()
Loads the xml representation of all the connected user's VMGroups.
-
infoGroup
public OneResponse infoGroup()
Loads the xml representation of all the connected user's VMGroups and the ones in his group.
-
info
public OneResponse info(int filter, int startId, int endId)
Retrieves all or part of the VMGroups in the pool. The VMGroups to retrieve can be also filtered by Id, specifying the first and last Id to include.- Overrides:
info
in classPool
- Parameters:
filter
- Filter flag to use. Possible values:Pool.ALL
: All VMGroupsPool.MINE
: Connected user's VMGroupsPool.MINE_GROUP
: Connected user's VMGroups, and the ones in his groupPool.GROUP
: User's primary group VMGroups- >= 0 UID User's VMGroups
startId
- Lowest Id to retrieveendId
- Biggest Id to retrieve- Returns:
- If successful the message contains the string with the information returned by OpenNebula.
-
iterator
public java.util.Iterator<VMGroup> iterator()
- Specified by:
iterator
in interfacejava.lang.Iterable<VMGroup>
-
-