de.fuberlin.wiwiss.d2rq.helpers
Class IndexArray

java.lang.Object
  extended byde.fuberlin.wiwiss.d2rq.helpers.IndexArray

public class IndexArray
extends java.lang.Object

An IndexArray is an array of (wrapped) counters. It can be used like an iterator.


Field Summary
 int[] counters
           
 int idx
           
 int n
           
 int[] ranges
           
 
Constructor Summary
IndexArray(int[] ranges)
           
 
Method Summary
 boolean hasNext()
           
 boolean hasPrev()
           
 int lastIndexChanged()
           
 int next()
           
 int prev()
           
static void test()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

n

public final int n

ranges

public final int[] ranges

counters

public int[] counters

idx

public int idx
Constructor Detail

IndexArray

public IndexArray(int[] ranges)
Method Detail

lastIndexChanged

public int lastIndexChanged()

hasNext

public boolean hasNext()

hasPrev

public boolean hasPrev()

next

public int next()

prev

public int prev()

test

public static void test()