public interface Model extends Cloneable, ElementBuilder
Mapping
to indicate the state
and the location of the elements, and a variety of ModelView
to
provide additional data about the elements.
In addition, it is possible to declare attributes for specific elements.
Modifier and Type | Method and Description |
---|---|
boolean |
attach(ModelView v)
Attach a view to the model.
|
void |
clearViews()
Detach all the views from this model.
|
Model |
clone()
Clone a model.
|
boolean |
detach(ModelView v)
Detach a view from this model.
|
Attributes |
getAttributes()
Get the attributes of the elements in the model.
|
Mapping |
getMapping()
Get the mapping associated to this model.
|
ModelView |
getView(String id)
Get a view already attached to the model
|
Collection<ModelView> |
getViews()
Get all the view attached to the model.
|
void |
setAttributes(Attributes attrs)
Set the attributes for the elements in the model.
|
ModelView getView(String id)
id
- the view identifiernull
otherwiseCollection<ModelView> getViews()
boolean attach(ModelView v)
v
- the view to attachtrue
iff the view has been attachedboolean detach(ModelView v)
v
- the viewtrue
iff the view was removedvoid clearViews()
Mapping getMapping()
Attributes getAttributes()
void setAttributes(Attributes attrs)
attrs
- the attributes to setModel clone()
clone
in interface ElementBuilder
Copyright © 2015 University of Nice-Sophia Antipolis. All Rights Reserved.