Class NoOverlap2dConstraint

java.lang.Object
com.google.ortools.sat.Constraint
com.google.ortools.sat.NoOverlap2dConstraint

public class NoOverlap2dConstraint extends Constraint
Specialized NoOverlap2D constraint.

This constraint allows adding rectangles to the NoOverlap2D constraint incrementally.

  • Constructor Details

  • Method Details

    • addRectangle

      public NoOverlap2dConstraint addRectangle(IntervalVar xInterval, IntervalVar yInterval)
      Adds a rectangle (xInterval, yInterval) to the constraint.
      Parameters:
      xInterval - the x interval of the rectangle.
      yInterval - the y interval of the rectangle.
      Returns:
      this constraint