jopt.csp.spi.arcalgorithm.domain
Interface LongDomain

All Superinterfaces:
Domain, NumDomain
All Known Implementing Classes:
BaseLongDomain, LongComputedDomain, LongDomainWrapper, SummationLongComputedDomain

public interface LongDomain
extends NumDomain

Interface implemented by long domains


Method Summary
 long getMax()
          Returns maximum value of domain
 long getMin()
          Returns minimum value of domain
 long getNextHigher(long val)
          Returns the next higher value in the domain or current value if none exists
 long getNextLower(long val)
          Returns the next lower value in the domain or current value if none exists
 boolean isInDomain(long val)
          Returns true if value is in domain
 void removeRange(long start, long end)
          Attempts to reduce domain by removing a range of values
 void removeValue(long val)
          Attempts to remove a single value from the domain
 void setMax(long val)
          Attempts to reduce domain to a maximum value.
 void setMin(long val)
          Attempts to reduce domain to a minimum value.
 void setRange(long start, long end)
          Attempts to reduce domain to within a range of values
 void setValue(long val)
          Attempts to reduce domain to a single value.
 
Methods inherited from interface jopt.csp.spi.arcalgorithm.domain.NumDomain
deltaValues, getDeltaSet, getSize, removeDomain, setDomain, toSet, values
 
Methods inherited from interface jopt.csp.spi.arcalgorithm.domain.Domain
changed, clearDelta, clone, getDomainState, isBound, restoreDomainState
 

Method Detail

getMax

public long getMax()
Returns maximum value of domain


getMin

public long getMin()
Returns minimum value of domain


isInDomain

public boolean isInDomain(long val)
Returns true if value is in domain


setMax

public void setMax(long val)
            throws jopt.csp.variable.PropagationFailureException
Attempts to reduce domain to a maximum value.

Throws:
jopt.csp.variable.PropagationFailureException - If domain is empty

setMin

public void setMin(long val)
            throws jopt.csp.variable.PropagationFailureException
Attempts to reduce domain to a minimum value.

Throws:
jopt.csp.variable.PropagationFailureException - If domain is empty

setValue

public void setValue(long val)
              throws jopt.csp.variable.PropagationFailureException
Attempts to reduce domain to a single value.

Throws:
jopt.csp.variable.PropagationFailureException - If domain is empty

removeValue

public void removeValue(long val)
                 throws jopt.csp.variable.PropagationFailureException
Attempts to remove a single value from the domain

Throws:
jopt.csp.variable.PropagationFailureException - If domain is empty

setRange

public void setRange(long start,
                     long end)
              throws jopt.csp.variable.PropagationFailureException
Attempts to reduce domain to within a range of values

Throws:
jopt.csp.variable.PropagationFailureException - If domain is empty

removeRange

public void removeRange(long start,
                        long end)
                 throws jopt.csp.variable.PropagationFailureException
Attempts to reduce domain by removing a range of values

Throws:
jopt.csp.variable.PropagationFailureException - If domain is empty

getNextHigher

public long getNextHigher(long val)
Returns the next higher value in the domain or current value if none exists


getNextLower

public long getNextLower(long val)
Returns the next lower value in the domain or current value if none exists