easik.sketch.constraint
Class SumConstraint
java.lang.Object
  
easik.sketch.vertex.SketchVertex
      
easik.sketch.constraint.Constraint
          
easik.sketch.constraint.SumConstraint
public class SumConstraint
- extends Constraint
 
This class represents the sum colimit constraint. It contains a list of
 paths sharing a target.
- Version:
 
  - 2006-07-13 Vera Ranieri
 
- Author:
 
  - Kevin Green 2006, Vera Ranieri 2006
 
 
 
 
| 
Constructor Summary | 
SumConstraint(java.util.ArrayList<SketchPath> inPaths)
 
          Default Constructor takes an ArrayList of SketchPaths | 
SumConstraint(java.util.ArrayList<SketchPath> inPaths,
              int x,
              int y,
              boolean isVisible)
 
          Constructor for specifying position on graph | 
 
| 
Method Summary | 
static boolean | 
isSumConstraint(java.util.ArrayList paths)
 
          Static method to determine whether a set of paths could theoretically 
 designate a sum constraint. | 
 void | 
setPaths(java.util.ArrayList<SketchPath> inPaths)
 
          Sets the path array, updates edge list, and updates display | 
 
| Methods inherited from class easik.sketch.constraint.Constraint | 
addEdges, addVisualsToSketch, getEdges, getNode, getPaths, getTablesInvolvedForError, getType, hasEdge, isDomainOrCoDomain, isVisible, setAllConstraintsVisible, setNode, setVisible, toString | 
 
 
| Methods inherited from class java.lang.Object | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
 
SumConstraint
public SumConstraint(java.util.ArrayList<SketchPath> inPaths)
- Default Constructor takes an ArrayList of SketchPaths
- Parameters:
 inPaths - An ArrayList of SketchPaths
 
SumConstraint
public SumConstraint(java.util.ArrayList<SketchPath> inPaths,
                     int x,
                     int y,
                     boolean isVisible)
- Constructor for specifying position on graph
- Parameters:
 inPaths - An ArrayList of SketchPathsx - X coordinate of visual on graphy - Y coordinate of visual on graphisVisible - If the constraint is visible in the graph or not
 
setPaths
public void setPaths(java.util.ArrayList<SketchPath> inPaths)
- Sets the path array, updates edge list, and updates display
- Parameters:
 inPaths - The new array of paths
 
 
isSumConstraint
public static boolean isSumConstraint(java.util.ArrayList paths)
- Static method to determine whether a set of paths could theoretically 
 designate a sum constraint.
- Parameters:
 paths - The paths to check for a sum constraint formation.
- Returns:
 - True if forms a sum constraint, false otherwise.
 - Since:
 
  - 2006-05-29 Vera Ranieri