Servertec
Jenie
1.0.1 09/04/2005

stec.jenie
Class BOOLArray

java.lang.Object
  extended by stec.jenie.NativeObject
      extended by stec.jenie.NativeArray
          extended by stec.jenie.BOOLArray

public class BOOLArray
extends NativeArray

Represents a native array of booleans.

Depending on the platform values are native 32-bit or 64-bit booleans.

Arrays can only be passed or returned by functions and callbacks as a pointer to the array.

Since:
1.0.0 12/05/2004

Constructor Summary
BOOLArray(BOOLArray array)
          Constructs a new n-dimensional array of booleans with the same number of dimensions and size of each dimension as the specified boolean native array.
BOOLArray(int size)
          Constructs a new one dimensional array of booleans of specified number of booleans.
BOOLArray(int[] dimensions)
          Constructs a new n-dimensional array of booleans of specified number of booleans.
BOOLArray(int size1, int size2)
          Constructs a new two dimensional array of booleans of specified number of booleans.
BOOLArray(int size1, int size2, int size3)
          Constructs a new three dimensional array of booleans of specified number of booleans.
BOOLArray(Pointer pointer, BOOLArray array)
          Constructs a new n-dimensional array of booleans from the specified pointer to a n-dimensional array of booleans with the same number of dimensions and size of each dimension as the specified boolean native array.
BOOLArray(Pointer pointer, int size)
          Constructs a new one dimensional array of booleans from the specified pointer to a one dimensional array of booleans of specified number of booleans.
BOOLArray(Pointer pointer, int[] dimensions)
          Constructs a new n-dimensional array of booleans from the specified pointer to a n-dimensional array of booleans of specified number of booleans.
BOOLArray(Pointer pointer, int size1, int size2)
          Constructs a new two dimensional array of booleans from the specified pointer to a two dimensional array of booleans of specified number of booleans.
BOOLArray(Pointer pointer, int size1, int size2, int size3)
          Constructs a new three dimensional array of booleans from the specified pointer to a three dimensional array of booleans of specified number of booleans.
 
Method Summary
 java.lang.Object clone()
          Returns a clone of this array of booleans.
 boolean equals(java.lang.Object object)
          Returns whether this array of booleans equals the specified object.
 boolean getValueAt(int index)
          Returns the value at the specified index.
 boolean getValueAt(int[] indexes)
          Returns the value at the specified index.
 boolean getValueAt(int index1, int index2)
          Returns the value at the specified index.
 boolean getValueAt(int index1, int index2, int index3)
          Returns the value at the specified index.
 void setValueAt(int[] indexes, BOOL value)
          Sets the value at the specified index.
 void setValueAt(int[] indexes, boolean value)
          Sets the value at the specified index.
 void setValueAt(int index, BOOL value)
          Sets the value at the specified index.
 void setValueAt(int index, boolean value)
          Sets the value at the specified index.
 void setValueAt(int index1, int index2, BOOL value)
          Sets the value at the specified index.
 void setValueAt(int index1, int index2, boolean value)
          Sets the value at the specified index.
 void setValueAt(int index1, int index2, int index3, BOOL value)
          Sets the value at the specified index.
 void setValueAt(int index1, int index2, int index3, boolean value)
          Sets the value at the specified index.
 
Methods inherited from class stec.jenie.NativeArray
getDimensions, getElementSize, getOffset, getOffset, getOffset, getOffset, i2a, i2a, i2a
 
Methods inherited from class stec.jenie.NativeObject
getAlignment, getNativeAddress, getNativeBuffer, getNativeBufferHandle, hashCode, setNativeBuffer, setNativeBuffer, setNativeBuffer, size
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BOOLArray

public BOOLArray(int size)
          throws java.lang.OutOfMemoryError,
                 java.lang.IllegalArgumentException
Constructs a new one dimensional array of booleans of specified number of booleans.

Parameters:
size - the number of booleans in the array.
Throws:
java.lang.OutOfMemoryError - if there is not enough free memory.
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(int size1,
                 int size2)
          throws java.lang.OutOfMemoryError,
                 java.lang.IllegalArgumentException
Constructs a new two dimensional array of booleans of specified number of booleans.

Parameters:
size1 - the size of the first dimension.
size2 - the size of the second dimension.
Throws:
java.lang.OutOfMemoryError - if there is not enough free memory.
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(int size1,
                 int size2,
                 int size3)
          throws java.lang.OutOfMemoryError,
                 java.lang.IllegalArgumentException
Constructs a new three dimensional array of booleans of specified number of booleans.

Parameters:
size1 - the size of the first dimension.
size2 - the size of the second dimension.
size3 - the size of the third dimension.
Throws:
java.lang.OutOfMemoryError - if there is not enough free memory.
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(int[] dimensions)
          throws java.lang.OutOfMemoryError,
                 java.lang.IllegalArgumentException
Constructs a new n-dimensional array of booleans of specified number of booleans.

Parameters:
dimensions - an array of booleans representing the number of dimensions and the size of each dimension.
Throws:
java.lang.OutOfMemoryError - if there is not enough free memory.
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(BOOLArray array)
          throws java.lang.OutOfMemoryError,
                 java.lang.IllegalArgumentException
Constructs a new n-dimensional array of booleans with the same number of dimensions and size of each dimension as the specified boolean native array.

Parameters:
array - the n-dimensional array of booleans to use.
Throws:
java.lang.OutOfMemoryError - if there is not enough free memory.
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(Pointer pointer,
                 int size)
          throws java.lang.IllegalArgumentException
Constructs a new one dimensional array of booleans from the specified pointer to a one dimensional array of booleans of specified number of booleans.

Parameters:
pointer - the pointer to the one dimensional array of booleans.
size - the number of booleans in the array.
Throws:
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(Pointer pointer,
                 int size1,
                 int size2)
          throws java.lang.IllegalArgumentException
Constructs a new two dimensional array of booleans from the specified pointer to a two dimensional array of booleans of specified number of booleans.

Parameters:
pointer - the pointer to the two dimensional array of booleans.
size1 - the size of the first dimension.
size2 - the size of the second dimension.
Throws:
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(Pointer pointer,
                 int size1,
                 int size2,
                 int size3)
          throws java.lang.IllegalArgumentException
Constructs a new three dimensional array of booleans from the specified pointer to a three dimensional array of booleans of specified number of booleans.

Parameters:
pointer - the pointer to the three dimensional array of booleans.
size1 - the size of the first dimension.
size2 - the size of the second dimension.
size3 - the size of the third dimension.
Throws:
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(Pointer pointer,
                 int[] dimensions)
          throws java.lang.IllegalArgumentException
Constructs a new n-dimensional array of booleans from the specified pointer to a n-dimensional array of booleans of specified number of booleans.

Parameters:
pointer - the pointer to the n-dimensional array of booleans.
dimensions - an array of booleans representing the number of dimensions and the size of each dimension.
Throws:
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.

BOOLArray

public BOOLArray(Pointer pointer,
                 BOOLArray array)
          throws java.lang.IllegalArgumentException
Constructs a new n-dimensional array of booleans from the specified pointer to a n-dimensional array of booleans with the same number of dimensions and size of each dimension as the specified boolean native array.

Parameters:
pointer - the pointer to the n-dimensional array of booleans.
array - the n-dimensional array of booleans to use.
Throws:
java.lang.IllegalArgumentException - if any of the specified parameters are invalid.
Method Detail

getValueAt

public boolean getValueAt(int index)
                   throws java.lang.ArrayIndexOutOfBoundsException
Returns the value at the specified index.

For use with one dimensional array of booleans.

Parameters:
index - the index of the value to return.
Returns:
the value at the specified index.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

getValueAt

public boolean getValueAt(int index1,
                          int index2)
                   throws java.lang.ArrayIndexOutOfBoundsException
Returns the value at the specified index.

For use with two dimensional array of booleans.

Parameters:
index1 - the index into the first dimension.
index2 - the index into the second dimension.
Returns:
the value at the specified index.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

getValueAt

public boolean getValueAt(int index1,
                          int index2,
                          int index3)
                   throws java.lang.ArrayIndexOutOfBoundsException
Returns the value at the specified index.

For use with three dimensional array of booleans.

Parameters:
index1 - the index into the first dimension.
index2 - the index into the second dimension.
index3 - the index into the third dimension.
Returns:
the value at the specified index.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

getValueAt

public boolean getValueAt(int[] indexes)
                   throws java.lang.ArrayIndexOutOfBoundsException
Returns the value at the specified index.

For use with n-dimensional array of booleans.

Parameters:
indexes - an array of booleans representing the number of indexes and the index into each of the dimensions.
Returns:
the value at the specified index.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int index,
                       boolean value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with one dimensional array of booleans.

Parameters:
index - the index of the value to change.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int index1,
                       int index2,
                       boolean value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with two dimensional array of booleans.

Parameters:
index1 - the index into the first dimension.
index2 - the index into the second dimension.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int index1,
                       int index2,
                       int index3,
                       boolean value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with three dimensional array of booleans.

Parameters:
index1 - the index into the first dimension.
index2 - the index into the second dimension.
index3 - the index into the third dimension.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int[] indexes,
                       boolean value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with n-dimensional array of booleans.

Parameters:
indexes - an array of booleans representing the number of indexes and the index into each of the dimensions.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int index,
                       BOOL value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with one dimensional array of booleans.

Parameters:
index - the index of the value to change.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int index1,
                       int index2,
                       BOOL value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with two dimensional array of booleans.

Parameters:
index1 - the index into the first dimension.
index2 - the index into the second dimension.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int index1,
                       int index2,
                       int index3,
                       BOOL value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with three dimensional array of booleans.

Parameters:
index1 - the index into the first dimension.
index2 - the index into the second dimension.
index3 - the index into the third dimension.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

setValueAt

public void setValueAt(int[] indexes,
                       BOOL value)
                throws java.lang.ArrayIndexOutOfBoundsException
Sets the value at the specified index.

For use with n-dimensional array of booleans.

Parameters:
indexes - an array of booleans representing the number of indexes and the index into each of the dimensions.
value - the value to use.
Throws:
java.lang.ArrayIndexOutOfBoundsException - if the specified index is out of bounds.

equals

public boolean equals(java.lang.Object object)
Returns whether this array of booleans equals the specified object.

Overrides:
equals in class NativeArray
Parameters:
object - the object to compare against.
Returns:
whether this array of booleans equals the specified object.

clone

public java.lang.Object clone()
                       throws java.lang.OutOfMemoryError
Returns a clone of this array of booleans.

Specified by:
clone in class NativeObject
Returns:
the clone of this array of booleans.
Throws:
java.lang.OutOfMemoryError - if there is not enough free memory.

Servertec
Jenie
1.0.1 09/04/2005

Copyright © 2004-2005 Servertec. All rights reserved.