|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.uci.ics.jung.utils.UserDataDelegate
edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph
public abstract class AbstractArchetypeGraph
Nested Class Summary | |
---|---|
protected class |
AbstractArchetypeGraph.Requirements
|
Nested classes/interfaces inherited from interface edu.uci.ics.jung.utils.UserDataContainer |
---|
UserDataContainer.CopyAction |
Field Summary | |
---|---|
protected AbstractArchetypeGraph.Requirements |
edge_requirements
|
protected Map |
mEdgeIDs
ID -> Edge lookup table. |
protected GraphListenerHandler |
mGraphListenerHandler
GraphEventType -> Graph Listener list table |
protected Map |
mVertexIDs
ID -> Vertex lookup table. |
protected AbstractArchetypeGraph.Requirements |
vertex_requirements
|
Fields inherited from class edu.uci.ics.jung.utils.UserDataDelegate |
---|
factory, udc_delegate |
Fields inherited from interface edu.uci.ics.jung.graph.ArchetypeGraph |
---|
SUBSET_MANAGER |
Constructor Summary | |
---|---|
AbstractArchetypeGraph()
|
Method Summary | |
---|---|
protected void |
addAllNotInitializers(Collection targetPredicates,
Collection sourcePredicates)
Adds all the predicates in source to the list in target, except those that answer to isInitializationPredicate. |
void |
addListener(GraphEventListener gel,
GraphEventType get)
Tells the graph to add gel as a listener for changes in the graph structure |
protected void |
checkConstraints(Object o,
Collection c)
|
ArchetypeGraph |
copy()
Creates a replica of this graph. |
Collection |
getEdgeConstraints()
Returns the Collection of requirements that each edge
must satisfy when it is added to this graph. |
Collection |
getVertexConstraints()
Returns the Collection of constraints that each vertex
must satisfy when it is added to this graph. |
protected void |
initialize()
Initializes all of the graph's internal data structures. |
protected boolean |
listenersExist(GraphEventType type)
|
ArchetypeGraph |
newInstance()
Creates a new empty graph of the same type as this graph, by cloning this graph and then clearing the extraneous fields. |
int |
numEdges()
Returns the number of edges in this graph. |
int |
numVertices()
Returns the number of vertices in this graph. |
void |
removeAllEdges()
Removes all edges from this graph. |
void |
removeAllVertices()
Removes all vertices (and, therefore, all edges) from this graph. |
void |
removeListener(GraphEventListener gel,
GraphEventType get)
Tells the graph to remove gel as a listener for changes in the graph structure |
String |
toString()
Returns a human-readable representation of this graph. |
Methods inherited from class edu.uci.ics.jung.utils.UserDataDelegate |
---|
addUserDatum, clone, containsUserDatumKey, getUserDatum, getUserDatumCopyAction, getUserDatumKeyIterator, importUserData, removeUserDatum, setUserDataFactory, setUserDatum |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface edu.uci.ics.jung.graph.ArchetypeGraph |
---|
getEdges, getVertices, removeEdges, removeVertices |
Methods inherited from interface edu.uci.ics.jung.utils.UserDataContainer |
---|
addUserDatum, clone, containsUserDatumKey, getUserDatum, getUserDatumCopyAction, getUserDatumKeyIterator, importUserData, removeUserDatum, setUserDatum |
Field Detail |
---|
protected GraphListenerHandler mGraphListenerHandler
protected Map mVertexIDs
protected Map mEdgeIDs
protected AbstractArchetypeGraph.Requirements edge_requirements
protected AbstractArchetypeGraph.Requirements vertex_requirements
Constructor Detail |
---|
public AbstractArchetypeGraph()
Method Detail |
---|
protected void initialize()
Note: this method is not a substitute for
removeAllVertices()
, as it will not notify the vertices
and edges that they have been removed from the graph.
public ArchetypeGraph newInstance()
newInstance
in interface ArchetypeGraph
ArchetypeGraph.newInstance()
protected void addAllNotInitializers(Collection targetPredicates, Collection sourcePredicates)
targetPredicates
- sourcePredicates
- public String toString()
toString
in class Object
Object.toString()
public int numVertices()
ArchetypeGraph
numVertices
in interface ArchetypeGraph
ArchetypeGraph.numVertices()
public int numEdges()
ArchetypeGraph
numEdges
in interface ArchetypeGraph
ArchetypeGraph.numEdges()
public Collection getVertexConstraints()
ArchetypeGraph
Collection
of constraints that each vertex
must satisfy when it is added to this graph. This collection may
be viewed and modified by the user to add or remove constraints.
getVertexConstraints
in interface ArchetypeGraph
ArchetypeGraph.getVertexConstraints()
public Collection getEdgeConstraints()
ArchetypeGraph
Collection
of requirements that each edge
must satisfy when it is added to this graph. This collection may
be viewed and modified by the user to add or remove requirements.
getEdgeConstraints
in interface ArchetypeGraph
ArchetypeGraph.getEdgeConstraints()
public void addListener(GraphEventListener gel, GraphEventType get)
ArchetypeGraph
addListener
in interface ArchetypeGraph
gel
- the graph event listenerget
- the type of graph events the listeners wants to listen forArchetypeGraph.addListener(edu.uci.ics.jung.graph.event.GraphEventListener,
edu.uci.ics.jung.graph.event.GraphEventType)
public void removeListener(GraphEventListener gel, GraphEventType get)
ArchetypeGraph
removeListener
in interface ArchetypeGraph
gel
- the graph event listenerget
- the type of graph events the listeners wants to not listen forArchetypeGraph.removeListener(edu.uci.ics.jung.graph.event.GraphEventListener,
edu.uci.ics.jung.graph.event.GraphEventType)
protected boolean listenersExist(GraphEventType type)
public ArchetypeGraph copy()
copy
in interface ArchetypeGraph
ArchetypeGraph.copy()
,
AbstractSparseEdge.copy(ArchetypeGraph)
,
AbstractSparseVertex.copy(ArchetypeGraph)
protected void checkConstraints(Object o, Collection c)
public void removeAllVertices()
removeVertex
on all
vertices of this graph.
removeAllVertices
in interface ArchetypeGraph
ArchetypeGraph.removeAllVertices()
public void removeAllEdges()
removeEdge
on all edges of this graph.
removeAllEdges
in interface ArchetypeGraph
ArchetypeGraph.removeAllEdges()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |