|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnz.ac.waikato.mcennis.rat.graph.model.ModelShell
nz.ac.waikato.mcennis.rat.graph.actor.BasicUser
public class BasicUser
Field Summary |
---|
Fields inherited from class nz.ac.waikato.mcennis.rat.graph.model.ModelShell |
---|
listener |
Constructor Summary | |
---|---|
BasicUser(java.lang.String ID)
Creates a new instance of BasicUser |
Method Summary | |
---|---|
void |
add(Page p)
Add a Page object to this class. |
void |
add(Property prop)
Add the given property to this user. |
protected int |
comparePages(Actor right)
Compare pages of this actor with the given actor. |
protected int |
compareProperties(Actor right)
Compare properties of this actor with the given actor. |
int |
compareTo(java.lang.Object o)
Throws ClassCastException when the parameter is not an Actor. |
Actor |
duplicate()
Return a copy of this Actor that is equal by compareTo() |
boolean |
equals(java.lang.Object obj)
implements equals in terms of CompareTo |
java.lang.String |
getID()
Return the id (unique within its type) |
Page[] |
getPage()
Returns the set of all page objects associated with this actor or null if no page objects havee been created |
Page |
getPage(java.lang.String ID)
Return the page with the given ID (usually a URI String) or null iuf it doesn't exist |
Property[] |
getProperty()
Return an array of all properties associated with this actor. |
Property |
getProperty(java.lang.String ID)
Return the property with the given value. |
java.lang.String |
getType()
Returns the type (mode) of this actor |
int |
hashCode()
|
void |
removeProperty(java.lang.String ID)
Remove a given property from this actor |
void |
setID(java.lang.String id)
Sets an id unique (which must be its type). |
void |
setType(java.lang.String type)
Set the type (mode) of this actor. |
java.lang.String |
toString()
|
Methods inherited from class nz.ac.waikato.mcennis.rat.graph.model.ModelShell |
---|
addListener, fireChange |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public BasicUser(java.lang.String ID)
Method Detail |
---|
public java.lang.String getID()
Actor
getID
in interface Actor
public Page[] getPage()
Actor
getPage
in interface Actor
public void add(Page p)
Actor
add
in interface Actor
p
- Page to be added.public Property[] getProperty()
Actor
getProperty
in interface Actor
public Page getPage(java.lang.String ID)
Actor
getPage
in interface Actor
ID
- id of the page to be returned
public Property getProperty(java.lang.String ID)
Actor
getProperty
in interface Actor
ID
- key-name for the property.
public void removeProperty(java.lang.String ID)
Actor
removeProperty
in interface Actor
ID
- key-name of property to remove.public void add(Property prop)
Actor
add
in interface Actor
prop
- property to be addedpublic void setType(java.lang.String type)
Actor
setType
in interface Actor
type
- new type (mode) of this actorpublic java.lang.String getType()
Actor
getType
in interface Actor
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
protected int compareProperties(Actor right)
right
- actor to be compared against
protected int comparePages(Actor right)
right
- actor to be compared against
public boolean equals(java.lang.Object obj)
equals
in interface Actor
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public void setID(java.lang.String id)
Actor
setID
in interface Actor
id
- ID this actor should be set topublic java.lang.String toString()
toString
in class java.lang.Object
public Actor duplicate()
Actor
duplicate
in interface Actor
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |