Top Description Fields Constructors Methods
com.googlecode.javaewah32.symmetric

public final Class EWAHPointer32

extends Object
implements Comparable<EWAHPointer32>
Class Inheritance
All Implemented Interfaces
java.lang.Comparable
Imports
com.googlecode.javaewah32.IteratingBufferedRunningLengthWord32

Wrapper around an IteratingBufferedRunningLengthWord used by the RunningBitmapMerge class.
Author
Daniel Lemire
Since
0.8.2

Field Summary

Modifier and TypeField and Description
private boolean
private int
private boolean
public final IteratingBufferedRunningLengthWord32
iterator

Underlying iterator

private final int
private boolean

Constructor Summary

AccessConstructor and Description
public
EWAHPointer32(final int
word where the previous run ended
previousEndRun
,
final IteratingBufferedRunningLengthWord32
the iterator
rw
,
final int
current position (in word)
pos
)

Construct a pointer over an IteratingBufferedRunningLengthWord.

Method Summary

Modifier and TypeMethod and Description
public int

Returns:

the beginning of the current run
beginOfRun
()

public void
callbackUpdate(final UpdateableBitmapFunction32
call the function with the current information
f
)

public int
compareTo(EWAHPointer32
the object to be compared.
other
)

Implements java.lang.Comparable.compareTo.

Compares this object with the specified object for order.

public int

Returns:

the end of the current run
endOfRun
()

public boolean

Returns:

true if there is no more data
hasNoData
()

public void
parseNextRun()

Process the next run

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

deadback to summary
private boolean dead
endrunback to summary
private int endrun
isLiteralback to summary
private boolean isLiteral
iteratorback to summary
public final IteratingBufferedRunningLengthWord32 iterator

Underlying iterator

posback to summary
private final int pos
valueback to summary
private boolean value

Constructor Detail

EWAHPointer32back to summary
public EWAHPointer32(final int previousEndRun, final IteratingBufferedRunningLengthWord32 rw, final int pos)

Construct a pointer over an IteratingBufferedRunningLengthWord.

Parameters
previousEndRun:int

word where the previous run ended

rw:IteratingBufferedRunningLengthWord32

the iterator

pos:int

current position (in word)

Method Detail

beginOfRunback to summary
public int beginOfRun()
Returns:int

the beginning of the current run

callbackUpdateback to summary
public void callbackUpdate(final UpdateableBitmapFunction32 f)
Parameters
f:UpdateableBitmapFunction32

call the function with the current information

compareToback to summary
public int compareTo(EWAHPointer32 other)

Implements java.lang.Comparable.compareTo.

Doc from java.lang.Comparable.compareTo.

Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.

The implementor must ensure signum(x.compareTo(y)) == -signum(y.compareTo(x)) for all x and y. (This implies that x.compareTo(y) must throw an exception if and only if y.compareTo(x) throws an exception.)

The implementor must also ensure that the relation is transitive: (x.compareTo(y) > 0 && y.compareTo(z) > 0) implies x.compareTo(z) > 0.

Finally, the implementor must ensure that x.compareTo(y)==0 implies that signum(x.compareTo(z)) == signum(y.compareTo(z)), for all z.

Parameters
other:EWAHPointer32

the object to be compared.

Returns:int

a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.

Annotations
@Override
endOfRunback to summary
public int endOfRun()
Returns:int

the end of the current run

hasNoDataback to summary
public boolean hasNoData()
Returns:boolean

true if there is no more data

parseNextRunback to summary
public void parseNextRun()

Process the next run