de.fuberlin.wiwiss.wiqa.extensions.tidal
Class SimpleTrustGraph
java.lang.Object
de.fuberlin.wiwiss.wiqa.extensions.tidal.SimpleTrustGraph
- public class SimpleTrustGraph
- extends Object
A directed graph whose edges are labeled with a
strength ranging from 1 to 10. Used as the
data structure for the Tidal Trust algorithm. Nodes
are identified by generic Java objects.
- Version:
- $Id$
- Author:
- Richard Cyganiak (richard@cyganiak.de)
SimpleTrustGraph
public SimpleTrustGraph()
addEdge
public void addEdge(Object from,
Object to,
double strength)
contains
public boolean contains(Object from,
Object to)
strength
public double strength(Object from,
Object to)
neighbours
public Collection neighbours(Object node)
- Returns the neighbour nodes of a node, or null
if the node is not in the graph.
- Parameters:
node - A node in the graph
- Returns:
- A collection of Objects, all neighbours of the node
size
public int size()
toString
public String toString()