public interface IFacetManager
EReference
s and EAttribute
s, and invoke EOperation
s.
Derived FacetAttribute
s and FacetReference
s are computed by queries, whereas
non-derived FacetAttribute
s and EAttribute
s and EReference
s and
FacetReference
s are stored in the serialization Resource
specified in the
IFacetManagerFactory
that created this IFacetManager
.
Modifier and Type | Method and Description |
---|---|
void |
addListener(IFacetManagerListener listener)
Adds a listener to this manager that will be notified when this manager's
state changes.
|
<T> java.util.List<ETypedElementResult> |
batchGetOrInvoke(java.util.Collection<EObject> sources,
ETypedElement query,
java.lang.Class<T> aClass) |
java.util.List<ETypedElementResult> |
batchInvoke(java.util.Collection<EObject> eObjects,
EOperation operation,
java.lang.Object... arguments)
Invoke the given
EOperation on each element of the given
collection of EObject s. |
java.util.Set<EAttribute> |
getAttributes(EObject eObject)
Get virtual attributes from an EObject.
|
java.util.List<FacetSet> |
getManagedFacetSets()
This method returns the list of loaded facet sets.
|
<T> T |
getOrInvoke(EObject element,
ETypedElement query,
java.lang.Class<T> aClass) |
<T> java.util.List<T> |
getOrInvokeMultiValued(EObject eObject,
ETypedElement feature,
java.lang.Class<T> aClass) |
java.util.Set<EReference> |
getReferences(EObject eObject)
Get virtual references from an EObject.
|
ResourceSet |
getResourceSet() |
Resource |
getSerializationResource() |
java.util.Set<EStructuralFeature> |
getStructuralFeature(EObject eObject)
Get virtual references and attributes from an EObject.
|
<T> T |
getSuperValueOf(DerivedTypedElement derivedTypedElt,
EObject source,
java.util.List<ParameterValue> parameterValues,
java.lang.Class<T> expectedType) |
<T> T |
invoke(EObject eObject,
EOperation operation,
java.lang.Class<T> resultType,
EditingDomain editingDomain,
java.lang.Object... arguments)
Evaluate the given
EOperation of the given EObject . |
boolean |
isConforming(EObject eObject,
Facet facet)
Returns whether the given model element conforms to the given Facet
|
void |
removeListener(IFacetManagerListener listener)
Removes a listener from this manager.
|
void |
saveStructuralFeatureInstanceModel()
Serialize the model containing the structural feature instances.
|
void |
set(EObject eObject,
EStructuralFeature structuralFeature,
java.lang.Object newValue,
EditingDomain editingDomain)
Set the value of the given
EStructuralFeature on the given
EObject to the given Object value. |
void |
setSerializationResource(Resource resource) |
void saveStructuralFeatureInstanceModel() throws FacetManagerException
FacetManagerException
boolean isConforming(EObject eObject, Facet facet) throws FacetManagerException
eObject
- the model elementfacet
- the Facet the applicability of which is being testedFacetManagerException
- if there is an error evaluating the Facet's conformance typed elementvoid set(EObject eObject, EStructuralFeature structuralFeature, java.lang.Object newValue, EditingDomain editingDomain) throws FacetManagerException
EStructuralFeature
on the given
EObject
to the given Object
value.eObject
- the model element whose feature must be setstructuralFeature
- the feature to setnewValue
- the new valueeditingDomain
- FacetManagerException
- <T> T invoke(EObject eObject, EOperation operation, java.lang.Class<T> resultType, EditingDomain editingDomain, java.lang.Object... arguments) throws FacetManagerException
EOperation
of the given EObject
. The
returned value has to be of the given expectedType Class
eObject
- the model element on which the operation is evaluatedoperation
- the operation to evaluateresultType
- the expected type of the returned value; if the effective type
is not compatible, an UnmatchingExpectedTypeException will be
thrownarguments
- the values of the parameters of the EOperation that is
evaluated: they must match both in size, types and
multiplicityFacetManagerException
- java.util.List<ETypedElementResult> batchInvoke(java.util.Collection<EObject> eObjects, EOperation operation, java.lang.Object... arguments) throws FacetManagerException
EOperation
on each element of the given
collection of EObject
s.eObjects
- the model elements on which the operation is evaluatedoperation
- the operation to evaluatearguments
- the values of the parameters of the EOperation that is
evaluated: they must match both in size, types and
multiplicityeObjects
FacetManagerException
- java.util.List<FacetSet> getManagedFacetSets()
ResourceSet getResourceSet()
<T> T getOrInvoke(EObject element, ETypedElement query, java.lang.Class<T> aClass) throws FacetManagerException
FacetManagerException
<T> java.util.List<T> getOrInvokeMultiValued(EObject eObject, ETypedElement feature, java.lang.Class<T> aClass) throws FacetManagerException
FacetManagerException
<T> java.util.List<ETypedElementResult> batchGetOrInvoke(java.util.Collection<EObject> sources, ETypedElement query, java.lang.Class<T> aClass) throws FacetManagerException
FacetManagerException
java.util.Set<EReference> getReferences(EObject eObject) throws FacetManagerException
eObject
- Model elementFacetManagerException
java.util.Set<EAttribute> getAttributes(EObject eObject) throws FacetManagerException
eObject
- Model elementFacetManagerException
java.util.Set<EStructuralFeature> getStructuralFeature(EObject eObject) throws FacetManagerException
eObject
- Model elementFacetManagerException
void addListener(IFacetManagerListener listener)
listener
- The listener to be addedvoid removeListener(IFacetManagerListener listener)
listener
- The listener to be removed<T> T getSuperValueOf(DerivedTypedElement derivedTypedElt, EObject source, java.util.List<ParameterValue> parameterValues, java.lang.Class<T> expectedType) throws SuperInvokeException, FacetManagerException
SuperInvokeException
FacetManagerException
Resource getSerializationResource()
void setSerializationResource(Resource resource) throws FacetManagerException
FacetManagerException