Modifier and Type | Field and Description |
---|---|
protected Client |
client |
protected int |
id |
protected org.w3c.dom.Node |
xml |
protected static javax.xml.xpath.XPath |
xpath |
Modifier | Constructor and Description |
---|---|
protected |
PoolElement(int id,
Client client)
Creates a new PoolElement with the specified attributes.
|
protected |
PoolElement(org.w3c.dom.Node xmlElement,
Client client)
Creates a new PoolElement from the xml provided.
|
Modifier and Type | Method and Description |
---|---|
protected static OneResponse |
chmod(Client client,
java.lang.String method,
int id,
int octet)
Changes the permissions
|
protected static OneResponse |
chmod(Client client,
java.lang.String method,
int id,
int owner_u,
int owner_m,
int owner_a,
int group_u,
int group_m,
int group_a,
int other_u,
int other_m,
int other_a)
Changes the permissions
|
protected static OneResponse |
chmod(Client client,
java.lang.String method,
int id,
java.lang.String octet)
Changes the permissions
|
java.lang.String |
getId()
Returns the element's ID.
|
java.lang.String |
getName()
Returns the element's name.
|
int |
gid()
Returns the element group's ID, or -1 if the element doesn't have one.
|
int |
id() |
protected void |
processInfo(OneResponse info)
After a *.info call, this method builds the internal xml
representation of the pool.
|
int |
state()
Performs an xpath evaluation for the "state" expression.
|
int |
uid()
Returns the owner User's ID, or -1 if the element doesn't have one.
|
java.lang.String |
xpath(java.lang.String expression)
Evaluates an XPath expression and returns the result as a String.
|
protected static javax.xml.xpath.XPath xpath
protected int id
protected org.w3c.dom.Node xml
protected Client client
protected PoolElement(int id, Client client)
id
- Id of the element.client
- XML-RPC Client.protected PoolElement(org.w3c.dom.Node xmlElement, Client client)
client
- XML-RPC Client.xmlElement
- XML representation of the element.protected void processInfo(OneResponse info)
info
- The XML-RPC *.info responseprotected static OneResponse chmod(Client client, java.lang.String method, int id, int owner_u, int owner_m, int owner_a, int group_u, int group_m, int group_a, int other_u, int other_m, int other_a)
client
- XML-RPC Client.method
- XML-RPC method.id
- The id of the target object.owner_u
- 1 to allow, 0 deny, -1 do not changeowner_m
- 1 to allow, 0 deny, -1 do not changeowner_a
- 1 to allow, 0 deny, -1 do not changegroup_u
- 1 to allow, 0 deny, -1 do not changegroup_m
- 1 to allow, 0 deny, -1 do not changegroup_a
- 1 to allow, 0 deny, -1 do not changeother_u
- 1 to allow, 0 deny, -1 do not changeother_m
- 1 to allow, 0 deny, -1 do not changeother_a
- 1 to allow, 0 deny, -1 do not changeprotected static OneResponse chmod(Client client, java.lang.String method, int id, java.lang.String octet)
client
- XML-RPC Client.method
- XML-RPC method.id
- The id of the target object.octet
- Permissions octet, e.g. 640protected static OneResponse chmod(Client client, java.lang.String method, int id, int octet)
client
- XML-RPC Client.method
- XML-RPC method.id
- The id of the target object.octet
- Permissions octed , e.g. 640public java.lang.String getId()
public int id()
public java.lang.String getName()
public int state()
public int uid()
public int gid()
public java.lang.String xpath(java.lang.String expression)
expression
- The XPath expression.Visit OpenNebula.org
Copyright 2002-2013 ©
OpenNebula Project (OpenNebula.org), C12G Labs.