|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eigenbase.jmi.JmiModelView
public class JmiModelView
JmiModelView represents an annotated view of a JMI model. Instances are immutable and can be accessed concurrently by multiple threads.
TODO: support transformations such as ignoring or reversing edges.
Nested Class Summary | |
---|---|
private static class |
JmiModelView.ClassAttributes
|
Field Summary | |
---|---|
private Map<JmiClassVertex,JmiModelView.ClassAttributes> |
classVertexAttributes
Map from JmiClassVertex to ClassAttributes. |
private JmiModelGraph |
modelGraph
Graph of the underlying model we are querying. |
Constructor Summary | |
---|---|
JmiModelView(JmiModelGraph modelGraph)
Creates a new view of a model. |
Method Summary | |
---|---|
private void |
deriveAttributes()
|
Set<JmiAssocEdge> |
getAllIncomingAssocEdges(JmiClassVertex vertex)
Gets the union of getInheritedIncomingAssocEdges() for all classes returned by getAllSubclassVertices(vertex). |
Set<JmiAssocEdge> |
getAllOutgoingAssocEdges(JmiClassVertex vertex)
Gets the union of getInheritedOutgoingAssocEdges() for all classes returned by getAllSubclassVertices(vertex). |
Set<JmiClassVertex> |
getAllSubclassVertices(JmiClassVertex vertex)
Gets all JmiClassVertexes representing subclasses of a class (including the class itself). |
Set<JmiClassVertex> |
getAllSuperclassVertices(JmiClassVertex vertex)
Gets all JmiClassVertexes representing superclasses of a class (including the class itself). |
private JmiModelView.ClassAttributes |
getClassAttributes(JmiClassVertex classVertex)
|
Set<JmiAssocEdge> |
getInheritedIncomingAssocEdges(JmiClassVertex vertex)
Gets all JmiAssocEdges representing associations incoming to any class vertex returned by getAllSuperclassVertices(vertex). |
Set<JmiAssocEdge> |
getInheritedOutgoingAssocEdges(JmiClassVertex vertex)
Gets all JmiAssocEdges representing associations outgoing from any class vertex returned by getAllSuperclassVertices(vertex). |
JmiModelGraph |
getModelGraph()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private final JmiModelGraph modelGraph
private Map<JmiClassVertex,JmiModelView.ClassAttributes> classVertexAttributes
Constructor Detail |
---|
public JmiModelView(JmiModelGraph modelGraph)
modelGraph
- graph for the underlying modelMethod Detail |
---|
public JmiModelGraph getModelGraph()
public Set<JmiClassVertex> getAllSuperclassVertices(JmiClassVertex vertex)
vertex
- vertex representing class of interest
public Set<JmiClassVertex> getAllSubclassVertices(JmiClassVertex vertex)
vertex
- vertex representing class of interest
public Set<JmiAssocEdge> getInheritedOutgoingAssocEdges(JmiClassVertex vertex)
vertex
- vertex representing class of interest
public Set<JmiAssocEdge> getInheritedIncomingAssocEdges(JmiClassVertex vertex)
vertex
- vertex representing class of interest
public Set<JmiAssocEdge> getAllOutgoingAssocEdges(JmiClassVertex vertex)
vertex
- vertex representing class of interest
public Set<JmiAssocEdge> getAllIncomingAssocEdges(JmiClassVertex vertex)
vertex
- vertex representing class of interest
private JmiModelView.ClassAttributes getClassAttributes(JmiClassVertex classVertex)
private void deriveAttributes()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |