Inheritance diagram for edu.cmu.hcii.calo.model.ManagedObject:
Public Member Functions | |
boolean | equals (Object obj) |
Tests if an object is equal to this managed object. | |
boolean | isCaloAdded () |
Accessor method for whether or not this item was added by the AI engine. | |
Calendar | getDateAdded () |
Accessor method for dateAdded. | |
int | hashCode () |
Returns a hash code for this managed object. | |
boolean | isManaged () |
Accessor method for isManaged. | |
void | setId (int id) |
Sets the ID of this managed object. | |
void | setManaged (boolean isManaged) |
Setter method for isManaged. | |
Protected Member Functions | |
int | getId () |
Accessor method for id. | |
void | setCaloAdded (boolean caloAdded) |
Setter method for caloAdded. | |
void | setDateAdded (Calendar dateAdded) |
Setter method for dateAdded. | |
Private Attributes | |
boolean | isManaged = false |
Whether or not this object is currently managed by a manager. | |
boolean | caloAdded |
Was this item added by the AI engine? | |
Calendar | dateAdded |
The date on which this item was added. | |
int | id = -1 |
The unique id of this item for lookup in its manager. |
boolean edu.cmu.hcii.calo.model.ManagedObject.equals | ( | Object | obj | ) |
Tests if an object is equal to this managed object.
If the object is unmanaged, it is just a reference equals. If this object is managed, then we compare unique management ids to determine equality. Don't assume something else; you will be wrong.
obj | the object to test equality with |
boolean edu.cmu.hcii.calo.model.ManagedObject.isCaloAdded | ( | ) |
Accessor method for whether or not this item was added by the AI engine.
Calendar edu.cmu.hcii.calo.model.ManagedObject.getDateAdded | ( | ) |
Accessor method for dateAdded.
Reimplemented in edu.cmu.hcii.calo.model.TaskGroup.
int edu.cmu.hcii.calo.model.ManagedObject.hashCode | ( | ) |
Returns a hash code for this managed object.
If the object is unmanaged, it is a reference hash; otherwise, it is based on the unique management id. Don't assume otherwise; you will be wrong.
boolean edu.cmu.hcii.calo.model.ManagedObject.isManaged | ( | ) |
Accessor method for isManaged.
void edu.cmu.hcii.calo.model.ManagedObject.setId | ( | int | id | ) |
Sets the ID of this managed object.
This should be called by the manager managing this object, and ensures that its equals() and hashCode() methods will continue to work if it is serialized and deserialized somewhere else.
id | the new ID of this object |
void edu.cmu.hcii.calo.model.ManagedObject.setManaged | ( | boolean | isManaged | ) |
Setter method for isManaged.
isManaged | the isManaged to set |
int edu.cmu.hcii.calo.model.ManagedObject.getId | ( | ) | [protected] |
Accessor method for id.
void edu.cmu.hcii.calo.model.ManagedObject.setCaloAdded | ( | boolean | caloAdded | ) | [protected] |
Setter method for caloAdded.
caloAdded | the caloAdded to set |
void edu.cmu.hcii.calo.model.ManagedObject.setDateAdded | ( | Calendar | dateAdded | ) | [protected] |
Setter method for dateAdded.
dateAdded | the dateAdded to set |
boolean edu.cmu.hcii.calo.model.ManagedObject.isManaged = false [private] |
Whether or not this object is currently managed by a manager.
(When objects are created, they are not managed, and changes to the object will not be propagated to any controllers.)
boolean edu.cmu.hcii.calo.model.ManagedObject.caloAdded [private] |
Was this item added by the AI engine?
Calendar edu.cmu.hcii.calo.model.ManagedObject.dateAdded [private] |
The date on which this item was added.
int edu.cmu.hcii.calo.model.ManagedObject.id = -1 [private] |
The unique id of this item for lookup in its manager.