|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
N
- the type of the object stored in each nodepublic interface LongGraph<N extends GObject>
Interface used to represent graphs whose edges contain long data.
Edges can be created only by invoking ObjectGraph.addEdge(galois.objects.graph.GNode
: invocations of
Graph.addNeighbor(GNode, GNode)
will result in a exception, because no edge data has been specified.
Method Summary | |
---|---|
boolean |
addEdge(GNode<N> src,
GNode<N> dst,
long data)
Adds an edge to the graph containing the specified data. |
boolean |
addEdge(GNode<N> src,
GNode<N> dst,
long data,
byte flags)
Adds an edge to the graph containing the specified data. |
long |
getEdgeData(GNode<N> src,
GNode<N> dst)
Retrieves the data associated with an edge. |
long |
getEdgeData(GNode<N> src,
GNode<N> dst,
byte flags)
Retrieves the data associated with an edge. |
long |
setEdgeData(GNode<N> src,
GNode<N> dst,
long d)
Sets the data associated with an edge. |
long |
setEdgeData(GNode<N> src,
GNode<N> dst,
long d,
byte flags)
Sets the data associated with an edge. |
Methods inherited from interface galois.objects.graph.Graph |
---|
add, add, addNeighbor, addNeighbor, contains, contains, createNode, createNode, hasNeighbor, hasNeighbor, inNeighborsSize, inNeighborsSize, isDirected, mapInNeighbors, mapInNeighbors, outNeighborsSize, outNeighborsSize, remove, remove, removeNeighbor, removeNeighbor, size, size |
Methods inherited from interface galois.objects.Mappable |
---|
map, map, map, map, map, map, mapInternal, mapInternal, mapInternal, mapInternalDone |
Methods inherited from interface galois.objects.GObject |
---|
access |
Method Detail |
---|
boolean addEdge(GNode<N> src, GNode<N> dst, long data)
All the Galois runtime actions (e.g., conflict detection) will be performed when the method is executed.
src
- the source node of the edgedst
- the destination node of the edgedata
- information to be stored in the new edge
boolean addEdge(GNode<N> src, GNode<N> dst, long data, byte flags)
src
- the source node of the edgedst
- the destination node of the edgedata
- information to be stored in the new edgeflags
- Galois runtime actions (e.g., conflict detection) that need to be executed
upon invocation of this method. See MethodFlag
long getEdgeData(GNode<N> src, GNode<N> dst)
Be aware that this method will return -1 in two cases:
In order to distinguish between the two cases, use Graph.hasNeighbor(GNode, GNode)
All the Galois runtime actions (e.g., conflict detection) will be performed when the method is executed.
src
- the source node of the edgedst
- the destination node of the edge
long getEdgeData(GNode<N> src, GNode<N> dst, byte flags)
Be aware that this method will return -1 in two cases:
In order to distinguish between the two cases, use Graph.hasNeighbor(GNode, GNode)
src
- the source node of the edgedst
- the destination node of the edgeflags
- Galois runtime actions (e.g., conflict detection) that need to be executed
upon invocation of this method. See MethodFlag
long setEdgeData(GNode<N> src, GNode<N> dst, long d)
All the Galois runtime actions (e.g., conflict detection) will be performed when the method is executed.
src
- the source node of the edgedst
- the destination node of the edged
- the data to associate with the edge
long setEdgeData(GNode<N> src, GNode<N> dst, long d, byte flags)
src
- the source node of the edgedst
- the destination node of the edged
- the data to associate with the edgeflags
- Galois runtime actions (e.g., conflict detection) that need to be executed
upon invocation of this method. See MethodFlag
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |