choco.cp.solver.constraints.global.tree.structure.internalStructure.graphStructures.graphViews
Class PrecsGraphView

java.lang.Object
  extended by choco.cp.solver.constraints.global.tree.structure.internalStructure.graphStructures.graphViews.PrecsGraphView

public class PrecsGraphView
extends Object


Field Summary
protected  boolean affiche
          boolean for debug and show a trace of the execution
protected static Logger LOGGER
           
protected  int nbNodes
          total number of nodes involved in the graph
protected  StoredBitSetGraph precs
          data structure of the precedence graph
protected  IStateBitSet[] precsGraph
          backtrackable bitset matrix representing the precedence graph
protected  List<StoredBitSetGraph.Maintain> precsParams
          list of graph properties to maintain for the precedence graph
protected  Solver solver
          Choco solver embedding the tree constraint
 
Constructor Summary
PrecsGraphView(Solver solver, Node[] nodes)
           
 
Method Summary
 boolean addPrec(int u, int v)
          incrementaly add the arc (u,v) in the precedence graph
 BitSet getAncestors(int i)
           
 BitSet getDescendants(int i)
           
 IStateBitSet[] getNumFromVertCC()
           
 StoredBitSetGraph getPrecs()
           
 IStateBitSet getPredecessors(int i)
           
 IStateBitSet getSinkNodes()
           
 IStateBitSet getSrcNodes()
           
 IStateBitSet getSuccessors(int i)
           
 IStateBitSet[] getVertFromNumCC()
           
 void showAllDesc()
           
 String showDesc(int i)
           
 void showPrecGraph()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOGGER

protected static final Logger LOGGER

affiche

protected boolean affiche
boolean for debug and show a trace of the execution


solver

protected Solver solver
Choco solver embedding the tree constraint


precsParams

protected List<StoredBitSetGraph.Maintain> precsParams
list of graph properties to maintain for the precedence graph


nbNodes

protected int nbNodes
total number of nodes involved in the graph


precs

protected StoredBitSetGraph precs
data structure of the precedence graph


precsGraph

protected IStateBitSet[] precsGraph
backtrackable bitset matrix representing the precedence graph

Constructor Detail

PrecsGraphView

public PrecsGraphView(Solver solver,
                      Node[] nodes)
Parameters:
solver - the Choco solver who uses the current tree constraint
nodes - total number of nodes involved in the graph
Method Detail

addPrec

public boolean addPrec(int u,
                       int v)
incrementaly add the arc (u,v) in the precedence graph

Parameters:
u - index of a node
v - index of a node
Returns:
true iff the arc (u,v) is effectively added in the precedence graph

getPrecs

public StoredBitSetGraph getPrecs()

getSuccessors

public IStateBitSet getSuccessors(int i)

getPredecessors

public IStateBitSet getPredecessors(int i)

getDescendants

public BitSet getDescendants(int i)

getAncestors

public BitSet getAncestors(int i)

getSinkNodes

public IStateBitSet getSinkNodes()

getSrcNodes

public IStateBitSet getSrcNodes()

getVertFromNumCC

public IStateBitSet[] getVertFromNumCC()

getNumFromVertCC

public IStateBitSet[] getNumFromVertCC()

showDesc

public String showDesc(int i)

showPrecGraph

public void showPrecGraph()

showAllDesc

public void showAllDesc()


Copyright © 2012. All Rights Reserved.