|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Class SearchableGraph defines the graph methods require for searching The vertices and edges for a searchable graph are untyped. It is the responsibility of the searchable graph to know how to iterate over the edges leaving a vertex and to determine the source and destination vertices of an edge.
A searchable graph that is designed to fit into application without requiring modification of the application should use the same kind of references for vertices and egdes that the application uses. For example, an airline software package will usually be able to determine the flights (edges) leaving an airport (a vertex) given the FAA name of the airport. Then the FAA names can be used as vertices in a searchable graph.
Method Summary | |
java.util.Iterator |
edgesFrom(java.lang.Object ov)
g.edgesFrom(ov) returns an iterator for the edges of g that leave ov. |
java.lang.Object |
getFromVertex(java.lang.Object oe)
g.getFromVertex(oe) returns the from (source) vertex of oe. |
java.lang.Object |
getToVertex(java.lang.Object oe)
g.getToVertex(oe) returns the to (destination) vertex of oe. |
Method Detail |
public java.lang.Object getFromVertex(java.lang.Object oe)
public java.lang.Object getToVertex(java.lang.Object oe)
public java.util.Iterator edgesFrom(java.lang.Object ov)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |