jist.swans.misc
Class Enumerator

java.lang.Object
  extended by jist.swans.misc.Enumerator

public class Enumerator
extends java.lang.Object

Class to generate a sequence; used usually for static initialization of constants.

Since:
SWANS1.0

Constructor Summary
Enumerator()
           
 
Method Summary
static int next()
          Return next value in sequence.
static int reset()
          Zero counter.
static int reset(int start)
          Reset counter value to given value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Enumerator

public Enumerator()
Method Detail

reset

public static int reset(int start)
Reset counter value to given value.

Parameters:
start - value to reset counter to
Returns:
the same value that the counter was reset to

reset

public static int reset()
Zero counter.

Returns:
zero

next

public static int next()
Return next value in sequence.

Returns:
next value in sequence