This class is used to represent the edges in a graph and will appear as links in the BRIDGES graph visualization: GraphAdjList and GraphAdjMatrix.
More...
|
| Edge (K from, K to, E2 data, LinkVisualizer lvis) |
| Construct an edge using each extremities, user data, and styling information. More...
|
|
| Edge (K from, K to, E2 data) |
| Construct an edge using each extremities, user data. More...
|
|
void | setFrom (K from) |
| Set source Element (Vertex) of the edge. More...
|
|
void | setTo (K to) |
| Set identifier of the terminating Element (Vertex) of edge. More...
|
|
K | getTo () |
| Get identifer of the terminating Element of edge. More...
|
|
K | getFrom () |
|
void | setEdgeData (E2 data) |
|
E2 | getEdgeData () |
|
LinkVisualizer | getLinkVisualizer () |
|
void | setLinkVisualizer (LinkVisualizer lvis) |
| Set the edge's link visualizer. More...
|
|
String | getLabel () |
| Get the edge's label. More...
|
|
void | setLabel (String label) |
| Set the edge's label. More...
|
|
double | getThickness () |
| Get the thickness of the edge. More...
|
|
void | setThickness (double thickness) |
| Set the thickness of the edge. More...
|
|
Color | getColor () |
| Get the color of the link in the Bridges Visualization. More...
|
|
void | setColor (Color color) |
| Set the color of the link from an existing Color object. More...
|
|
void | setColor (String color) |
| Set the color of the link in the Bridges Visualization. More...
|
|
void | setColor (int r, int g, int b, float a) |
| Set the color of the link given RGBA components. More...
|
|
This class is used to represent the edges in a graph and will appear as links in the BRIDGES graph visualization: GraphAdjList and GraphAdjMatrix.
This object is used in graphs and graph algorithms such as DFS, BFS and shortest path algorithms that need to visit graph edges. The adjacency list representation uses them as the generic paramter, as SLelement<Edge> Bridges represents Edges as links between pairs of elements.
- See also
- the tutorial on using graphs in BRIDGES: https://bridgesuncc.github.io/tutorials/Graph.html and https://bridgesuncc.github.io/tutorials/Graph_AM.html
- Author
- Kalpathi Subramanian
- Parameters
-
K | holds the terminating vertex of the edge |
E2 | holds edge specific information |
◆ Edge() [1/2]
Construct an edge using each extremities, user data, and styling information.
- Parameters
-
from | key of source vertex of the edge |
to | key of terminating vertex of the edge |
data | is the edge information object |
lvis | is the object storing styling information for the edge |
◆ Edge() [2/2]
Construct an edge using each extremities, user data.
- Parameters
-
from | key of source vertex of the edge |
to | key of terminating vertex of the edge |
data | is the edge information object |
◆ getColor()
Get the color of the link in the Bridges Visualization.
- Returns
- the edge color
◆ getEdgeData()
Get edge specific data.
- Returns
- edge data
◆ getFrom()
Get identifer of the source Element of edge
- Returns
- the identifier of the source Element
◆ getLabel()
Get the edge's label.
- Returns
- label of this edge
◆ getLinkVisualizer()
Get the edge's link visualizer
- Returns
- link visualizer for this edge
◆ getThickness()
Get the thickness of the edge.
- Returns
- the size in pixels of the edge
◆ getTo()
Get identifer of the terminating Element of edge.
- Returns
- the identifier of the terminating Element (vertex)
◆ setColor() [1/3]
Set the color of the link from an existing Color object.
- Parameters
-
color | the edge color to be assigned |
◆ setColor() [2/3]
Set the color of the link given RGBA components.
- Parameters
-
r | red component |
g | green component |
b | blue component |
a | alpha (transparency) component |
◆ setColor() [3/3]
Set the color of the link in the Bridges Visualization.
- Parameters
-
color | the string reprsenting the color. See the Color class for the complete set of supported colors. |
◆ setEdgeData()
Set edge specific data.
- Parameters
-
◆ setFrom()
Set source Element (Vertex) of the edge.
- Parameters
-
from | the identifier of the source Element (Vertex) |
◆ setLabel()
Set the edge's label.
- Parameters
-
label | the label to be assigned |
◆ setLinkVisualizer()
Set the edge's link visualizer.
- Parameters
-
lvis | link visualizer to be set for this edge |
◆ setThickness()
Set the thickness of the edge.
- Parameters
-
thickness | edge thickness to set |
◆ setTo()
Set identifier of the terminating Element (Vertex) of edge.
- Parameters
-
to | the identifier of the terminating Element (Vertex) |
The documentation for this class was generated from the following file:
- bridges-java/src/main/java/bridges/base/Edge.java