Top Description Inners Fields Constructors Methods
com.googlecode.javaewah32

public Class NonEmptyVirtualStorage32

extends Object
implements BitmapStorage32
Class Inheritance
All Implemented Interfaces
com.googlecode.javaewah32.BitmapStorage32

This is a BitmapStorage that can be used to determine quickly if the result of an operation is non-trivial... that is, whether there will be at least on set bit.
Author
Daniel Lemire and Veronika Zenz
Since
0.5.0

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class

Field Summary

Modifier and TypeField and Description
private static final NonEmptyVirtualStorage32.NonEmptyException

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
addLiteralWord(int
the word
newData
)

Implements com.googlecode.javaewah32.BitmapStorage32.addLiteralWord.

If the word to be added is non-zero, a NonEmptyException exception is thrown.

public void
addStreamOfEmptyWords(boolean
zeros or ones
v
,
int
how many to words add
number
)

Implements com.googlecode.javaewah32.BitmapStorage32.addStreamOfEmptyWords.

If the boolean value is true and number is greater than 0, then it throws a NonEmptyException exception, otherwise, nothing happens.

public void
addStreamOfLiteralWords(Buffer32
the buffer wrapping the literal words
buffer
,
int
the starting point in the array
start
,
int
the number of literal words to add
number
)

Implements com.googlecode.javaewah32.BitmapStorage32.addStreamOfLiteralWords.

throws a NonEmptyException exception when number is greater than 0

public void
addStreamOfNegatedLiteralWords(Buffer32
the buffer wrapping the literal words
buffer
,
int
the starting point in the array
start
,
int
the number of literal words to add
number
)

Implements com.googlecode.javaewah32.BitmapStorage32.addStreamOfNegatedLiteralWords.

throws a NonEmptyException exception when number is greater than 0

public void
addWord(int
the word
newData
)

Implements com.googlecode.javaewah32.BitmapStorage32.addWord.

If the word to be added is non-zero, a NonEmptyException exception is thrown.

public void
clear()

Implements com.googlecode.javaewah32.BitmapStorage32.clear.

Empties the container.

public void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

nonEmptyExceptionback to summary
private static final NonEmptyVirtualStorage32.NonEmptyException nonEmptyException

Constructor Detail

NonEmptyVirtualStorage32back to summary
public NonEmptyVirtualStorage32()

Method Detail

addLiteralWordback to summary
public void addLiteralWord(int newData)

Implements com.googlecode.javaewah32.BitmapStorage32.addLiteralWord.

If the word to be added is non-zero, a NonEmptyException exception is thrown.

Parameters
newData:int

Doc from com.googlecode.javaewah32.BitmapStorage32.addLiteralWord.

the word

Annotations
@Override
addStreamOfEmptyWordsback to summary
public void addStreamOfEmptyWords(boolean v, int number)

Implements com.googlecode.javaewah32.BitmapStorage32.addStreamOfEmptyWords.

If the boolean value is true and number is greater than 0, then it throws a NonEmptyException exception, otherwise, nothing happens.

Parameters
v:boolean

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfEmptyWords.

zeros or ones

number:int

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfEmptyWords.

how many to words add

Annotations
@Override
addStreamOfLiteralWordsback to summary
public void addStreamOfLiteralWords(Buffer32 buffer, int start, int number)

Implements com.googlecode.javaewah32.BitmapStorage32.addStreamOfLiteralWords.

throws a NonEmptyException exception when number is greater than 0

Parameters
buffer:Buffer32

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfLiteralWords.

the buffer wrapping the literal words

start:int

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfLiteralWords.

the starting point in the array

number:int

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfLiteralWords.

the number of literal words to add

Annotations
@Override
addStreamOfNegatedLiteralWordsback to summary
public void addStreamOfNegatedLiteralWords(Buffer32 buffer, int start, int number)

Implements com.googlecode.javaewah32.BitmapStorage32.addStreamOfNegatedLiteralWords.

throws a NonEmptyException exception when number is greater than 0

Parameters
buffer:Buffer32

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfNegatedLiteralWords.

the buffer wrapping the literal words

start:int

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfNegatedLiteralWords.

the starting point in the array

number:int

Doc from com.googlecode.javaewah32.BitmapStorage32.addStreamOfNegatedLiteralWords.

the number of literal words to add

Annotations
@Override
addWordback to summary
public void addWord(int newData)

Implements com.googlecode.javaewah32.BitmapStorage32.addWord.

If the word to be added is non-zero, a NonEmptyException exception is thrown.

Parameters
newData:int

Doc from com.googlecode.javaewah32.BitmapStorage32.addWord.

the word

Annotations
@Override
clearback to summary
public void clear()

Implements com.googlecode.javaewah32.BitmapStorage32.clear.

Doc from com.googlecode.javaewah32.BitmapStorage32.clear.

Empties the container.

Annotations
@Override
setSizeInBitsWithinLastWordback to summary
public void setSizeInBitsWithinLastWord(int bits)

Implements com.googlecode.javaewah32.BitmapStorage32.setSizeInBitsWithinLastWord.

Does nothing.

Parameters
bits:int

Doc from com.googlecode.javaewah32.BitmapStorage32.setSizeInBitsWithinLastWord.

the size in bits

Annotations
@Override
See Also
com.googlecode.javaewah.BitmapStorage#setSizeInBitsWithinLastWord(int)
com.googlecode.javaewah32 back to summary

pack-priv Class NonEmptyVirtualStorage32.NonEmptyException

extends RuntimeException
Class Inheritance

Field Summary

Modifier and TypeField and Description
private static final long

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public synchronized Throwable

Returns:

this instance
fillInStackTrace
()

Overrides java.lang.Throwable.fillInStackTrace.

Do not fill in the stack trace for this exception for performance reasons.

Field Detail

serialVersionUIDback to summary
private static final long serialVersionUID

Hides java.lang.RuntimeException.serialVersionUID.

Constructor Detail

NonEmptyExceptionback to summary
pack-priv NonEmptyException()

Method Detail

fillInStackTraceback to summary
public synchronized Throwable fillInStackTrace()

Overrides java.lang.Throwable.fillInStackTrace.

Do not fill in the stack trace for this exception for performance reasons.

Returns:Throwable

this instance

Annotations
@Override
See Also
java.lang.Throwable#fillInStackTrace()