|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.xensource.xenapi.XenAPIObject
com.xensource.xenapi.Subject
public class Subject
A user or group that can log in xapi
Nested Class Summary | |
---|---|
static class |
Subject.Record
Represents all the fields in a Subject |
Field Summary | |
---|---|
protected java.lang.String |
ref
The XenAPI reference to this object. |
Method Summary | |
---|---|
void |
addToRoles(Connection c,
Role role)
This call adds a new role to a subject |
static Subject |
create(Connection c,
Subject.Record record)
Create a new subject instance, and return its handle. |
static Task |
createAsync(Connection c,
Subject.Record record)
Create a new subject instance, and return its handle. |
void |
destroy(Connection c)
Destroy the specified subject instance. |
Task |
destroyAsync(Connection c)
Destroy the specified subject instance. |
boolean |
equals(java.lang.Object obj)
If obj is a Subject, compares XenAPI references for equality. |
static java.util.Set<Subject> |
getAll(Connection c)
Return a list of all the subjects known to the system. |
static java.util.Map<Subject,Subject.Record> |
getAllRecords(Connection c)
Return a map of subject references to subject records for all subjects known to the system. |
static Subject |
getByUuid(Connection c,
java.lang.String uuid)
Get a reference to the subject instance with the specified UUID. |
java.util.Map<java.lang.String,java.lang.String> |
getOtherConfig(Connection c)
Get the other_config field of the given subject. |
java.util.Set<java.lang.String> |
getPermissionsNameLabel(Connection c)
This call returns a list of permission names given a subject |
Subject.Record |
getRecord(Connection c)
Get a record containing the current state of the given subject. |
java.util.Set<Role> |
getRoles(Connection c)
Get the roles field of the given subject. |
java.lang.String |
getSubjectIdentifier(Connection c)
Get the subject_identifier field of the given subject. |
java.lang.String |
getUuid(Connection c)
Get the uuid field of the given subject. |
int |
hashCode()
|
void |
removeFromRoles(Connection c,
Role role)
This call removes a role from a subject |
java.lang.String |
toWireString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final java.lang.String ref
Method Detail |
---|
public java.lang.String toWireString()
toWireString
in class XenAPIObject
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public Subject.Record getRecord(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public static Subject getByUuid(Connection c, java.lang.String uuid) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
uuid
- UUID of object to return
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public static Task createAsync(Connection c, Subject.Record record) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
record
- All constructor arguments
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public static Subject create(Connection c, Subject.Record record) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
record
- All constructor arguments
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public Task destroyAsync(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public void destroy(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public java.lang.String getUuid(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public java.lang.String getSubjectIdentifier(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public java.util.Map<java.lang.String,java.lang.String> getOtherConfig(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public java.util.Set<Role> getRoles(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public void addToRoles(Connection c, Role role) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
role
- The unique role reference
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public void removeFromRoles(Connection c, Role role) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
role
- The unique role reference in the subject's roles field
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public java.util.Set<java.lang.String> getPermissionsNameLabel(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public static java.util.Set<Subject> getAll(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
public static java.util.Map<Subject,Subject.Record> getAllRecords(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException
Types.BadServerResponse
Types.XenAPIException
org.apache.xmlrpc.XmlRpcException
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |