TopologicalGraph

public class TopologicalGraph

This class represents a graph containing vertices (nodes) and edges (links), used for input with a network-layer.

Graphical-Output Restricions:

  • EdgeColors: GraphicalProperties.getColorEdge
  • NodeColors: GraphicalProperties.getColorNode
Author:Thomas Hohnstein

Constructors

TopologicalGraph

public TopologicalGraph()

Creates an empty graph-object.

Methods

addNode

public void addNode(TopologicalNode node)

Adds an Topological Node to this graph.

Parameters:
  • node – the topological node to add

getNodeList

public List<TopologicalNode> getNodeList()

Gets a read-only list of nodes of the network graph.

getNumberOfNodes

public int getNumberOfNodes()

Gets the number of nodes contained inside the topological-graph.

Returns:number of nodes

toString

public String toString()