JaCoP.core
Class BoundDomainValueEnumeration

java.lang.Object
  extended by JaCoP.core.ValueEnumeration
      extended by JaCoP.core.BoundDomainValueEnumeration

public class BoundDomainValueEnumeration
extends ValueEnumeration

Defines a methods for enumerating values contained in the BoundDomain.

Version:
3.1
Author:
Radoslaw Szymanek and Krzysztof Kuchcinski

Constructor Summary
BoundDomainValueEnumeration(BoundDomain dom)
           
 
Method Summary
 void domainHasChanged()
          This function is called to inform enumeration of the change of the domain it enumerates over.
 boolean hasMoreElements()
          It checks if the value enumeration has more elements.
 int nextElement()
          It returns the next element in the enumeration.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BoundDomainValueEnumeration

public BoundDomainValueEnumeration(BoundDomain dom)
Parameters:
dom - It specifies the BoundDomain for which enumeration of values is performed.
Method Detail

hasMoreElements

public boolean hasMoreElements()
Description copied from class: ValueEnumeration
It checks if the value enumeration has more elements.

Specified by:
hasMoreElements in class ValueEnumeration
Returns:
true if more elements can be enumerated, false otherwise.

nextElement

public int nextElement()
Description copied from class: ValueEnumeration
It returns the next element in the enumeration.

Specified by:
nextElement in class ValueEnumeration
Returns:
the next element.

domainHasChanged

public void domainHasChanged()
Description copied from class: ValueEnumeration
This function is called to inform enumeration of the change of the domain it enumerates over. The enumeration will update its private data structure and if possible adapt next element to the closest (on the right) which is still in the domain.

Specified by:
domainHasChanged in class ValueEnumeration