TopologicalGraph (cloudsim 3.1-SNAPSHOT API)

org.cloudbus.cloudsim.network

## Class TopologicalGraph

- java.lang.Object
- - org.cloudbus.cloudsim.network.TopologicalGraph

-     public class TopologicalGraph
      extends Object

  This class represents an graph containing nodes and edges, used for input with an network-layer Graphical-Output Restricions! EdgeColors: GraphicalProperties.getColorEdge NodeColors: GraphicalProperties.getColorNode
  Since:
    CloudSim Toolkit 1.0
  Author:
    Thomas Hohnstein

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `TopologicalGraph()` just the constructor to create an empty graph-object

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addLink(TopologicalLink edge)` adds an link between two topological nodes
    `void` | `addNode(TopologicalNode node)` adds an Topological Node to this graph
    `Iterator<TopologicalLink>` | `getLinkIterator()` return an iterator through all network-graph links
    `Iterator<TopologicalNode>` | `getNodeIterator()` returns an iterator through all network-graph nodes
    `int` | `getNumberOfLinks()` returns the number of links contained inside the topological-graph
    `int` | `getNumberOfNodes()` returns the number of nodes contained inside the topological-graph
    `String` | `toString()` prints out all internal node and link information

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### TopologicalGraph

          public TopologicalGraph()

      just the constructor to create an empty graph-object

  - ### Method Detail

    - #### addLink

          public void addLink(TopologicalLink edge)

      adds an link between two topological nodes
      Parameters:
        `edge` - the topological link

    - #### addNode

          public void addNode(TopologicalNode node)

      adds an Topological Node to this graph
      Parameters:
        `node` - the topological node to add

    - #### getNumberOfNodes

          public int getNumberOfNodes()

      returns the number of nodes contained inside the topological-graph
      Returns:
        number of nodes

    - #### getNumberOfLinks

          public int getNumberOfLinks()

      returns the number of links contained inside the topological-graph
      Returns:
        number of links

    - #### getLinkIterator

          public Iterator<TopologicalLink> getLinkIterator()

      return an iterator through all network-graph links
      Returns:
        the iterator throug all links

    - #### getNodeIterator

          public Iterator<TopologicalNode> getNodeIterator()

      returns an iterator through all network-graph nodes
      Returns:
        the iterator through all nodes

    - #### toString

          public String toString()

      prints out all internal node and link information
      Overrides:
        `toString` in class `Object`

Copyright © 2013 The Cloud Computing and Distributed Systems (CLOUDS) Laboratory, The University of Melbourne. All Rights Reserved.