com.googlecode.javaewah
Class EWAHIterator

java.lang.Object
  extended by com.googlecode.javaewah.EWAHIterator

public final class EWAHIterator
extends Object

The class EWAHIterator represents a special type of efficient iterator iterating over (uncompressed) words of bits.

Since:
0.1.0
Author:
Daniel Lemire

Constructor Summary
EWAHIterator(long[] a, int sizeinwords)
          Instantiates a new eWAH iterator.
 
Method Summary
 long[] buffer()
          Access to the array of words
static EWAHIterator getEWAHIterator(EWAHCompressedBitmap bitmap)
          Allow expert developers to instantiate an EWAHIterator.
 boolean hasNext()
          Checks for next.
 int literalWords()
          Position of the literal words represented by this running length word.
 RunningLengthWord next()
          Next running length word.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EWAHIterator

public EWAHIterator(long[] a,
                    int sizeinwords)
Instantiates a new eWAH iterator.

Parameters:
a - the array of words
sizeinwords - the number of words that are significant in the array of words
Method Detail

getEWAHIterator

public static EWAHIterator getEWAHIterator(EWAHCompressedBitmap bitmap)
Allow expert developers to instantiate an EWAHIterator.

Parameters:
bitmap -
Returns:
an iterator

buffer

public long[] buffer()
Access to the array of words

Returns:
the long[]

literalWords

public int literalWords()
Position of the literal words represented by this running length word.

Returns:
the int

hasNext

public boolean hasNext()
Checks for next.

Returns:
true, if successful

next

public RunningLengthWord next()
Next running length word.

Returns:
the running length word


Copyright © 2013. All Rights Reserved.