|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectedu.usc.cse.desi.model.AbstractDESIModel
edu.usc.cse.desi.model.view.AbstractViewModel
edu.usc.cse.desi.model.view.DESIViewModel
The view model class that cooresponds with the DESIDataModel class. Pay special attention to the static fields and methods that are used to maintain mappings between view model object and data model objects.
| Field Summary | |
private java.util.List |
myHosts
|
private java.util.BitSet |
myPointBitSet
|
private static java.util.HashMap |
myViewModelMappings
|
private DeSiDataModel |
myXADLModel
|
| Fields inherited from class edu.usc.cse.desi.model.view.AbstractViewModel |
myDataModel |
| Fields inherited from class edu.usc.cse.desi.model.AbstractDESIModel |
listeners |
| Constructor Summary | |
DESIViewModel(DESIDataModel data)
Take the passed-in model and ennumerate through all its children, creating associtated *View* objects for each *Data* object. |
|
DESIViewModel(PropertyInitializer prop_init)
|
|
| Method Summary | |
void |
addHost(HostViewModel host)
This is the public version of addHost. |
static void |
createModelMapping(AbstractDataModel data_model,
AbstractViewModel view_model)
This method really should only be called by the reinitialize methods. |
java.lang.String |
debugOutput()
This method will output a string that you can use to see the structure of the view model. |
void |
finalize()
Just to make sure that nothing keeps this class as a listener after the object has been eliminated. |
static AbstractDataModel |
getMappedDataModel(AbstractViewModel view_model,
PropertyInitializer prop_init)
This method is to be used when someone create an AbstractViewModel without passing it a AbstractDataModel. |
static AbstractViewModel |
getMappedViewModel(AbstractDataModel data_model_object)
This method is how the view classes examine their relationships with data model objects. |
java.util.List |
getMyHosts()
Returns a list of HostViewModels. |
PropertyInitializer |
getMyPropertyInitializer()
|
DeSiDataModel |
getMyXADLModel()
|
private void |
privateAddHost(HostViewModel host)
Adds new host and then updates all listeners. |
private void |
privateRemoveHost(HostViewModel host)
Removes the given host and updates all listeners. |
void |
propertyChange(java.beans.PropertyChangeEvent evt)
On propertyChange, this class will respond to any additions or subtractions of Hosts by the DESIDataModel. |
void |
reinitialize()
Must call reinitialize on the view model first, so that all view models will be able to add themselves as listeners. |
void |
removeHost(HostViewModel host)
This is the public version of removeHost. |
void |
setMyXADLModel(DeSiDataModel myXADLModel)
This method will attach a XADL model to this model. |
| Methods inherited from class edu.usc.cse.desi.model.view.AbstractViewModel |
getMyDataModel, getMyPropetyInitializer, getProperties, getPropertyDisplayName, getPropertyValue, hasProperty, setPropertyValue |
| Methods inherited from class edu.usc.cse.desi.model.AbstractDESIModel |
addPropertyChangeListener, firePropertyChange, removePropertyChangeListener |
| Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private static java.util.HashMap myViewModelMappings
private java.util.List myHosts
private java.util.BitSet myPointBitSet
private transient DeSiDataModel myXADLModel
| Constructor Detail |
public DESIViewModel(PropertyInitializer prop_init)
public DESIViewModel(DESIDataModel data)
data - DESIDataModel| Method Detail |
public void reinitialize()
reinitialize in class AbstractViewModelAbstractDESIModel.reinitialize()
public void finalize()
throws java.lang.Throwable
java.lang.Throwablepublic PropertyInitializer getMyPropertyInitializer()
public void propertyChange(java.beans.PropertyChangeEvent evt)
propertyChange in interface java.beans.PropertyChangeListenerpropertyChange in class AbstractDESIModelpublic java.util.List getMyHosts()
public void setMyXADLModel(DeSiDataModel myXADLModel)
myXADLModel - The myXADLModel to set.public DeSiDataModel getMyXADLModel()
private void privateAddHost(HostViewModel host)
host - HostViewModelprivate void privateRemoveHost(HostViewModel host)
host - HostViewModelpublic void addHost(HostViewModel host)
host - public void removeHost(HostViewModel host)
host - HostViewModel Host to remove.public static AbstractViewModel getMappedViewModel(AbstractDataModel data_model_object)
data_model_object - AbstractDataModel - The data model object that you want to get the cooresponding view model object for.
public static AbstractDataModel getMappedDataModel(AbstractViewModel view_model,
PropertyInitializer prop_init)
view_model - prop_init -
public static void createModelMapping(AbstractDataModel data_model,
AbstractViewModel view_model)
data_model - view_model - public java.lang.String debugOutput()
Object.toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||