Class UniformInOut<V,​E>

  • All Implemented Interfaces:
    org.apache.commons.collections4.Transformer<VEPair<V,​E>,​java.lang.Double>

    public class UniformInOut<V,​E>
    extends java.lang.Object
    implements org.apache.commons.collections4.Transformer<VEPair<V,​E>,​java.lang.Double>
    Assigns weights to directed edges (the edge of the vertex/edge pair) depending on whether the vertex is the edge's source or its destination. If the vertex v is the edge's source, assigns 1/outdegree(v). Otherwise, assigns 1/indegree(w). Throws IllegalArgumentException if the edge is not directed.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected edu.uci.ics.jung.graph.Graph<V,​E> graph
      The graph for which the edge weights are defined.
    • Constructor Summary

      Constructors 
      Constructor Description
      UniformInOut​(edu.uci.ics.jung.graph.Graph<V,​E> graph)
      Creates an instance for the specified graph.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Double transform​(VEPair<V,​E> ve_pair)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • graph

        protected edu.uci.ics.jung.graph.Graph<V,​E> graph
        The graph for which the edge weights are defined.
    • Constructor Detail

      • UniformInOut

        public UniformInOut​(edu.uci.ics.jung.graph.Graph<V,​E> graph)
        Creates an instance for the specified graph.
        Parameters:
        graph - the graph for which the edge weights will be defined
    • Method Detail

      • transform

        public java.lang.Double transform​(VEPair<V,​E> ve_pair)
        Specified by:
        transform in interface org.apache.commons.collections4.Transformer<V,​E>
        Throws:
        java.lang.IllegalArgumentException
        See Also:
        Transformer.transform(Object)