|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface EGraph
Interface for storing EObject
graphs.
Method Summary | |
---|---|
boolean |
addGraph(EObject object)
Adds an EObject and all reachable objects to this graph. |
boolean |
addTree(EObject root)
Adds an EObject and all its children to this graph. |
EGraph |
copy(Map<EObject,EObject> copies)
Copy this object graph. |
ECrossReferenceAdapter |
getCrossReferenceAdapter()
Get the cross reference adapter of this graph. |
List<EObject> |
getDomain(EClass type,
boolean strict)
Get all EObject s of this graph which are compatible with the given type. |
int |
getDomainSize(EClass type,
boolean strict)
Returns the size of the domain for a type. |
List<EObject> |
getRoots()
Get the root objects in this graph. |
boolean |
removeGraph(EObject object)
Removes an EObject and all reachable objects from this graph. |
boolean |
removeTree(EObject root)
Removes an EObject and all its children from this graph. |
Methods inherited from interface java.util.Collection |
---|
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray |
Method Detail |
---|
boolean addTree(EObject root)
EObject
and all its children to this graph.
root
- The root object of the tree.
true
if an object was added.boolean addGraph(EObject object)
EObject
and all reachable objects to this graph.
In contrast to addTree(EObject)
this method adds all
referenced objects to the graph, and not just the children of
the containment tree.
object
- An arbitrary object.
true
if at least one object was added.boolean removeTree(EObject root)
EObject
and all its children from this graph.
root
- The root object of the tree.
true
if any object was removed.addTree(EObject)
boolean removeGraph(EObject object)
EObject
and all reachable objects from this graph.
object
- An arbitrary object.
true
if any object was removed.addGraph(EObject)
EGraph copy(Map<EObject,EObject> copies)
null
the objects in the graph will be copied too. If the map is not
null
, the images of the map will be used as the new
objects.
copies
- Map associating object of this graph to copies. Can be null
.
EGraph
.List<EObject> getDomain(EClass type, boolean strict)
EObject
s of this graph which are compatible with the given type.
This returns a fresh and modifiable list.
type
- The type of the objects.strict
- Whether subtypes are excluded from the result.
EObject
s compatible with the type.int getDomainSize(EClass type, boolean strict)
getDomain(EClass, boolean)
.
This method should be used whenever the actual objects are not needed.
type
- The type.strict
- Whether subtypes are excluded.
List<EObject> getRoots()
ECrossReferenceAdapter getCrossReferenceAdapter()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |