it.unimi.dico.islab.idbs2.cloud
Class CloudEdge

java.lang.Object
  extended by it.unimi.dico.islab.idbs2.cloud.CloudEdge

public class CloudEdge
extends Object

Representation of a directed edge connecting two nodes of the cloud. An object of this class is composed by a pointer to the starting node and a pointer to the target node (as the represented edge is always directed). The last component is a weight value.

Author:
Vegeziel
See Also:
CloudNode, Cloud

Method Summary
 Integer getId()
          Get the id of the corresponding database persisted object.
 CloudNode getSource()
          Getter for the starting (source) node of this edge.
 CloudNode getTarget()
          Getter for the ending (target) node of this edge.
 double getWeight()
          Getter for the weight parameter of this edge.
 void setWeight(double weight)
          Setter for the weight parameter (could be used to modify the value set with the constructor).
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getId

public Integer getId()

Get the id of the corresponding database persisted object.

Returns:
the identifier (primary key) of the corresponding row on the relational Hibernate-mapped relational database.

setWeight

public void setWeight(double weight)

Setter for the weight parameter (could be used to modify the value set with the constructor).

Parameters:
weight - the weight of this edge.

getWeight

public double getWeight()

Getter for the weight parameter of this edge.

Returns:
the weight value of this edge.

getSource

public CloudNode getSource()

Getter for the starting (source) node of this edge.

Returns:
the source node of this edge.

getTarget

public CloudNode getTarget()

Getter for the ending (target) node of this edge.

Returns:
the target node of this edge.

toString

public String toString()
Overrides:
toString in class Object