org.javanetworkanalyzer.analyzers
Class WeightedGraphAnalyzer<E extends EdgeCent>

java.lang.Object
  extended by org.javanetworkanalyzer.analyzers.GeneralizedGraphAnalyzer<V,E>
      extended by org.javanetworkanalyzer.analyzers.GraphAnalyzer<VWCent,E,WeightedPathLengthData>
          extended by org.javanetworkanalyzer.analyzers.WeightedGraphAnalyzer<E>

public class WeightedGraphAnalyzer<E extends EdgeCent>
extends GraphAnalyzer<VWCent,E,WeightedPathLengthData>

Calculates various centrality measures on weighted graphs which are assumed to be connected.

Author:
Adam Gouge

Field Summary
 
Fields inherited from class org.javanetworkanalyzer.analyzers.GraphAnalyzer
pm, stack
 
Fields inherited from class org.javanetworkanalyzer.analyzers.GeneralizedGraphAnalyzer
graph, nodeCount, nodeSet
 
Constructor Summary
WeightedGraphAnalyzer(org.jgrapht.WeightedGraph<VWCent,E> graph)
          Initializes a new instance of a weighted graph analyzer that doesn't keep track of progress.
WeightedGraphAnalyzer(org.jgrapht.WeightedGraph<VWCent,E> graph, ProgressMonitor pm)
          Initializes a new instance of a weighted graph analyzer with the given ProgressMonitor.
 
Method Summary
protected  DijkstraForCentrality<E> calculateShortestPathsFromNode(VWCent startNode)
          Stores number of shortest paths and the length of these paths from startNode to every other node in the V of every other node; also updates the predecessor sets.
 void computeAll()
          Performs graph analysis and stores the results in a hash map, mapping each node to a data structure holding the results of the analysis.
 
Methods inherited from class org.javanetworkanalyzer.analyzers.GraphAnalyzer
calculateClosenessForNode
 
Methods inherited from class org.javanetworkanalyzer.analyzers.GeneralizedGraphAnalyzer
getGraph
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WeightedGraphAnalyzer

public WeightedGraphAnalyzer(org.jgrapht.WeightedGraph<VWCent,E> graph,
                             ProgressMonitor pm)
                      throws NoSuchMethodException,
                             InstantiationException,
                             IllegalAccessException,
                             IllegalArgumentException,
                             InvocationTargetException
Initializes a new instance of a weighted graph analyzer with the given ProgressMonitor.

Parameters:
graph - The graph to be analyzed.
pm - The ProgressMonitor to be used.
Throws:
NoSuchMethodException
InstantiationException
IllegalAccessException
IllegalArgumentException
InvocationTargetException

WeightedGraphAnalyzer

public WeightedGraphAnalyzer(org.jgrapht.WeightedGraph<VWCent,E> graph)
                      throws NoSuchMethodException,
                             InstantiationException,
                             IllegalAccessException,
                             IllegalArgumentException,
                             InvocationTargetException
Initializes a new instance of a weighted graph analyzer that doesn't keep track of progress.

Parameters:
graph - The graph to be analyzed.
Throws:
NoSuchMethodException
InstantiationException
IllegalAccessException
IllegalArgumentException
InvocationTargetException
Method Detail

calculateShortestPathsFromNode

protected DijkstraForCentrality<E> calculateShortestPathsFromNode(VWCent startNode)
Stores number of shortest paths and the length of these paths from startNode to every other node in the V of every other node; also updates the predecessor sets.

Specified by:
calculateShortestPathsFromNode in class GraphAnalyzer<VWCent,E extends EdgeCent,WeightedPathLengthData>
Parameters:
startNode - Start node
Returns:
The GraphSearchAlgorithm used to find the shortest paths.

computeAll

public void computeAll()
                throws InstantiationException,
                       IllegalAccessException,
                       IllegalArgumentException,
                       InvocationTargetException
Description copied from class: GraphAnalyzer
Performs graph analysis and stores the results in a hash map, mapping each node to a data structure holding the results of the analysis.

Overrides:
computeAll in class GraphAnalyzer<VWCent,E extends EdgeCent,WeightedPathLengthData>
Throws:
InstantiationException
IllegalAccessException
IllegalArgumentException
InvocationTargetException


Copyright © 2014. All Rights Reserved.