helix.graph.algo.c3part.preprocessor
Class MultiGraphCloser

java.lang.Object
  extended by helix.graph.algo.c3part.preprocessor.GraphPreprocessor
      extended by helix.graph.algo.c3part.preprocessor.GraphCloser
          extended by helix.graph.algo.c3part.preprocessor.MultiGraphCloser

public class MultiGraphCloser
extends GraphCloser

a class to compute delta closure of multigraph.
this is used in conjunction with a Chromatizer to implements delta shuffling
in a multigraph only edges are assumed to be colored (not necessarily vertices) and polychromatic.
note: color 0 is assumed to be unused (epsilon relation)
For later retrieval, the colors of newly colored edges are shifted by a specified amount. By default this shift amount equals the maxcolor parameter given in constructor and should therefore equal the maximal color in the source datagraph i.e. the number of colors in the source datagraph minus one.


Constructor Summary
MultiGraphCloser(List<Integer> delta, int maxColor)
          special constructor with shift = maxColor
MultiGraphCloser(List<Integer> delta, int maxColor, int shift)
          constructor close on all colors (except color 0) with deltas given in delta list.
 
Method Summary
 void run(Graph graph)
          implement our run() operation
 
Methods inherited from class helix.graph.algo.c3part.preprocessor.GraphCloser
logParams, makeDeltaList
 
Methods inherited from class helix.graph.algo.c3part.preprocessor.GraphPreprocessor
run
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MultiGraphCloser

public MultiGraphCloser(List<Integer> delta,
                        int maxColor,
                        int shift)
constructor close on all colors (except color 0) with deltas given in delta list. To avoid closing on a color, use a delta value of 0 for this color.

Parameters:
maxColor - maximum color to use normally this should equal the number of colors in the source datagraph minus 1 (because color 0 is unused)
delta - delta list. List size should be >= maxColor or 1. In the latter case, the same delta is assumed for all colors.
shift - specified shift. Usually this should be maxColor or 0

MultiGraphCloser

public MultiGraphCloser(List<Integer> delta,
                        int maxColor)
special constructor with shift = maxColor

Method Detail

run

public void run(Graph graph)
implement our run() operation

Specified by:
run in class GraphPreprocessor