Class CoreConstraintStore

java.lang.Object
org.projog.core.predicate.builtin.clp.CoreConstraintStore
All Implemented Interfaces:
org.projog.clp.ConstraintStore, org.projog.clp.ReadConstraintStore

final class CoreConstraintStore extends Object implements org.projog.clp.ConstraintStore
An implementation of ConstraintStore for use in Projog.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final Set<org.projog.clp.Constraint>
     
    private final List<org.projog.clp.Constraint>
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    CoreConstraintStore(List<org.projog.clp.Constraint> c)
     
    CoreConstraintStore(org.projog.clp.Constraint c)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    private void
     
    long
    getMax(org.projog.clp.Expression id)
     
    long
    getMin(org.projog.clp.Expression id)
     
    (package private) boolean
     
    org.projog.clp.ExpressionResult
    setMax(org.projog.clp.Expression id, long max)
     
    org.projog.clp.ExpressionResult
    setMin(org.projog.clp.Expression id, long min)
     
    org.projog.clp.ExpressionResult
    setNot(org.projog.clp.Expression id, long not)
     
    org.projog.clp.ExpressionResult
    setValue(org.projog.clp.Expression id, long value)
     
    private org.projog.clp.ExpressionResult
    update(org.projog.clp.Expression id, Function<org.projog.clp.VariableState, org.projog.clp.VariableStateResult> f)
     

    Methods inherited from class Object

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

    • queue

      private final List<org.projog.clp.Constraint> queue
    • matched

      private final Set<org.projog.clp.Constraint> matched
  • Constructor Details

    • CoreConstraintStore

      CoreConstraintStore()
    • CoreConstraintStore

      CoreConstraintStore(org.projog.clp.Constraint c)
    • CoreConstraintStore

      CoreConstraintStore(List<org.projog.clp.Constraint> c)
  • Method Details

    • resolve

      boolean resolve()
    • getMin

      public long getMin(org.projog.clp.Expression id)
      Specified by:
      getMin in interface org.projog.clp.ReadConstraintStore
    • getMax

      public long getMax(org.projog.clp.Expression id)
      Specified by:
      getMax in interface org.projog.clp.ReadConstraintStore
    • setValue

      public org.projog.clp.ExpressionResult setValue(org.projog.clp.Expression id, long value)
      Specified by:
      setValue in interface org.projog.clp.ConstraintStore
    • setMin

      public org.projog.clp.ExpressionResult setMin(org.projog.clp.Expression id, long min)
      Specified by:
      setMin in interface org.projog.clp.ConstraintStore
    • setMax

      public org.projog.clp.ExpressionResult setMax(org.projog.clp.Expression id, long max)
      Specified by:
      setMax in interface org.projog.clp.ConstraintStore
    • setNot

      public org.projog.clp.ExpressionResult setNot(org.projog.clp.Expression id, long not)
      Specified by:
      setNot in interface org.projog.clp.ConstraintStore
    • update

      private org.projog.clp.ExpressionResult update(org.projog.clp.Expression id, Function<org.projog.clp.VariableState, org.projog.clp.VariableStateResult> f)
    • addConstraints

      private void addConstraints(ClpVariable copy)