|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface UIObject
A construct that mirrors a domain object and adds UI things. A UIObject has a base object which is its corresponding object in the domain. The contents of this object may change - it is a clone of what is in the domain. The UIObject also has a reference that can be used to identify its corresponding object in the domain (e.g. for a refinement that should be its name). Once this is set, it should not be changed. It will be needed if the domain has to work out what the original is (in case of remove or update operations)
Method Summary | |
---|---|
void |
addToDomain(Domain domain)
Adds the contents of this UIObject to the domain (part of publish). |
java.util.List |
collectChanges()
Collects the object's changes since it was last saved to draft. |
java.util.List |
collectChangesFromOriginal()
Collects the object's changes since it was last published. |
java.lang.Class |
getBaseClass()
Gets the class of objects that can represent this one in the domain. |
IXObject |
getBaseObject()
Gets the object that corresponds to this one in the domain. |
java.lang.Object |
getBaseReference()
Gets the Id that can be used to identify the base object in the domain. |
Domain |
getDomain()
Gets the base domain. |
IXObject |
getOriginal()
Gets the object that corresponds to this one in the original domain. |
UIDomain |
getUIDomain()
Gets the ui domain of which this object is part. |
boolean |
hasChanged()
Determines whether the object has changed since it was last saved to draft |
boolean |
hasChangedFromOriginal()
Determines whether the object has changed from its original. |
boolean |
hasOriginal()
Determines whether the object has an original in the base domain. |
boolean |
isEmpty()
Determines whether the object has any information in it. |
void |
loadFromDomain()
Loads the contents of this object from its corresponding domain object. |
void |
loadFromDomain(java.lang.Object domainObject)
Loads the contents of this object from the given object. |
void |
loadFromOriginal()
Loads the contents of this object from its original domain object. |
IXObject |
makeBaseObject()
Makes an empty object of the right class that can represent this UIObject in the domain. |
void |
moveToUIDomain(UIDomain uiDomain)
Move the object from its current UIDomain to the given one. |
boolean |
nameHasChanged(java.lang.Object nameThing)
Determines whether the object's identifying fields have changed |
void |
noteChange()
Get the UIDomain to note the change of this object. |
java.lang.String |
print()
|
void |
removeFromDomain(Domain domain)
Removes the object's corresponding base object from the domain. |
boolean |
sameValue(java.lang.String field,
java.lang.Object value,
java.lang.Object otherValue)
Determines whether the two given values of the given field differ |
void |
saveToDomain()
Saves the contents of this object into its corresponding domain object. |
void |
saveToDomain(java.lang.Object domainObject)
Saves the contents of this object into the given object. |
void |
setBaseObject(IXObject object)
Sets the object that will represent this one in the domain. |
void |
setBaseReference(java.lang.Object id)
Sets the Id that can be used to identify the base object in the domain. |
void |
setName(java.lang.String name)
|
boolean |
setValue(java.lang.String field,
java.lang.Object value)
Sets the given field to the given value. |
void |
updateInDomain(Domain domain)
Updates the base object in the domain with the contents of this object. |
Methods inherited from interface ix.iview.domain.UIEditableObject |
---|
isUndefined |
Methods inherited from interface ix.iface.ui.EditableObject |
---|
addDataChangeListener, removeDataChangeListener |
Methods inherited from interface ix.icore.domain.Named |
---|
getName |
Method Detail |
---|
Domain getDomain()
UIDomain getUIDomain()
boolean hasOriginal()
hasOriginal
in interface UIEditableObject
boolean isEmpty()
isEmpty
in interface UIEditableObject
boolean hasChangedFromOriginal()
hasChangedFromOriginal
in interface UIEditableObject
boolean hasChanged()
hasChanged
in interface UIEditableObject
java.util.List collectChanges()
java.util.List collectChangesFromOriginal()
boolean setValue(java.lang.String field, java.lang.Object value)
setValue
in interface EditableObject
boolean sameValue(java.lang.String field, java.lang.Object value, java.lang.Object otherValue)
sameValue
in interface EditableObject
boolean nameHasChanged(java.lang.Object nameThing)
java.lang.Object getBaseReference()
void setBaseReference(java.lang.Object id)
IXObject getOriginal()
IXObject getBaseObject()
getBaseObject
in interface UIEditableObject
IXObject makeBaseObject()
void setBaseObject(IXObject object)
java.lang.Class getBaseClass()
void saveToDomain()
void saveToDomain(java.lang.Object domainObject)
void loadFromDomain()
void loadFromDomain(java.lang.Object domainObject)
void loadFromOriginal()
void noteChange()
void addToDomain(Domain domain)
void updateInDomain(Domain domain)
void removeFromDomain(Domain domain)
void moveToUIDomain(UIDomain uiDomain)
void setName(java.lang.String name)
java.lang.String print()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |