public class ModelGroup extends Model
Modifier and Type | Class and Description |
---|---|
class |
ModelGroup.DelegatingModelElementPropertyGetter |
class |
ModelGroup.DelegatingModelElementPropertySetter |
Modifier and Type | Field and Description |
---|---|
protected ArrayList<IModel> |
models |
aliases, ENV_PREFIX, name, PROPERTY_ALIASES, PROPERTY_NAME, PROPERTY_READONLOAD, PROPERTY_READONLY, PROPERTY_STOREONDISPOSAL, propertyGetter, propertySetter, readOnLoad, storeOnDisposal
Constructor and Description |
---|
ModelGroup() |
ModelGroup(ModelRepository repository,
String metaModel) |
Modifier and Type | Method and Description |
---|---|
Collection<?> |
allContents()
Returns a collection containing all of the objects contained in
this model.
|
Object |
createInstance(String metaClass) |
Object |
createInstance(String metaClass,
Collection<Object> parameters) |
void |
deleteElement(Object instance) |
void |
dispose() |
Collection<?> |
getAllOfKind(String metaClass) |
Collection<?> |
getAllOfType(String metaClass) |
Object |
getElementById(String id) |
String |
getElementId(Object instance) |
Object |
getEnumerationValue(String enumeration,
String label) |
String |
getMetaModel() |
ArrayList<IModel> |
getModels() |
IPropertySetter |
getPropertySetter() |
String |
getTypeNameOf(Object instance)
Returns a string representing the type of the instance object.
|
Object |
getTypeOf(Object instance) |
boolean |
hasType(String metaClass) |
boolean |
isInstantiable(String metaClass) |
boolean |
isModelElement(Object instance)
Used to test whether a Java object can be contained by this model.
|
boolean |
isOfKind(Object instance,
String metaClass) |
boolean |
isOfType(Object instance,
String metaClass) |
boolean |
knowsAboutProperty(Object instance,
String property)
Returns
true if this instance could have this property at some point. |
void |
load() |
void |
load(StringProperties properties,
IRelativePathResolver resolver) |
boolean |
owns(Object instance)
Used to test whether an object is contained in this model.
|
void |
setElementId(Object instance,
String newId) |
boolean |
store() |
boolean |
store(String fileName) |
allInstances, getAliases, getFullyQualifiedTypeNameOf, getMetamodel, getName, getPropertyGetter, getTransactionSupport, isPropertySet, isReadOnLoad, isStoredOnDisposal, load, load, setName, setReadOnLoad, setStoredOnDisposal
public ModelGroup()
public ModelGroup(ModelRepository repository, String metaModel) throws EolModelNotFoundException
EolModelNotFoundException
public void load() throws EolModelLoadingException
EolModelLoadingException
public String getMetaModel()
public Object getEnumerationValue(String enumeration, String label) throws EolEnumerationValueNotFoundException
public Collection<?> getAllOfType(String metaClass) throws EolModelElementTypeNotFoundException
public Collection<?> getAllOfKind(String metaClass) throws EolModelElementTypeNotFoundException
public Collection<?> allContents()
IModel
public String getTypeNameOf(Object instance)
IModel
instance
- The model object whose type is to be determined.public Object createInstance(String metaClass, Collection<Object> parameters) throws EolModelElementTypeNotFoundException, EolNotInstantiableModelElementTypeException
createInstance
in interface IModel
createInstance
in class Model
EolModelElementTypeNotFoundException
EolNotInstantiableModelElementTypeException
public Object createInstance(String metaClass) throws EolModelElementTypeNotFoundException, EolNotInstantiableModelElementTypeException
public void deleteElement(Object instance) throws EolRuntimeException
EolRuntimeException
public boolean owns(Object instance)
IModel
instance
- the Java object to test.public boolean knowsAboutProperty(Object instance, String property)
IModel
true
if this instance could have this property at some point.knowsAboutProperty
in interface IModel
knowsAboutProperty
in class Model
public boolean store(String fileName)
public boolean store()
public void dispose()
public boolean isInstantiable(String metaClass)
public boolean hasType(String metaClass)
public boolean isOfKind(Object instance, String metaClass) throws EolModelElementTypeNotFoundException
isOfKind
in interface IModel
isOfKind
in class Model
EolModelElementTypeNotFoundException
public boolean isOfType(Object instance, String metaClass) throws EolModelElementTypeNotFoundException
isOfType
in interface IModel
isOfType
in class Model
EolModelElementTypeNotFoundException
public void load(StringProperties properties, IRelativePathResolver resolver) throws EolModelLoadingException
load
in interface IModel
load
in class Model
EolModelLoadingException
public boolean isModelElement(Object instance)
IModel
isModelElement
in interface IModel
isModelElement
in class Model
instance
- the Java object to test.public IPropertySetter getPropertySetter()
getPropertySetter
in interface IModel
getPropertySetter
in class Model
Copyright © 2020. All rights reserved.