public class IntervalRange extends java.lang.Object implements Range
"new IntervalRange(0, 3)" enumerates 0, 1, 2.
Constructor and Description |
---|
IntervalRange(int a,
int b)
Construct new interval range.
|
Modifier and Type | Method and Description |
---|---|
boolean |
hasMore()
More indices available?
|
int |
index()
Consecutive numbering of current index.
|
void |
init(int lower,
int upper)
Initialize Range to available indices
|
int |
length()
Total number of indices.
|
void |
next()
Increase counter.
|
java.lang.String |
toString() |
int |
value()
Get current index.
|
public IntervalRange(int a, int b)
public void init(int lower, int upper)
Range
public int index()
Range
public java.lang.String toString()
toString
in class java.lang.Object
© 2008-2013 by Mikio L. Braun and contributors