com.jniwrapper
Class Pointer.Void

java.lang.Object
  |
  +--com.jniwrapper.Parameter
        |
        +--com.jniwrapper.Pointer.Void
Enclosing class:
Pointer

public static class Pointer.Void
extends Parameter

Represents a void *. This pointer can be used for parameters where the referenced object type/size is not known or is of no interest for the client. Good example of such object is Win32 HANDLE type.


Constructor Summary
Pointer.Void()
          Constructs a new null pointer.
Pointer.Void(long value)
          Constructs a new void pointer that has the given value.
 
Method Summary
 java.lang.Object clone()
           
 int getLength()
          Returns a length of the parameter in memory.
 long getValue()
          Returns handle value of this object.
 boolean isNull()
          Tests if this pointer is null.
 void read(DataBuffer stackBuffer, int offset)
          Reads this parameter from a specified data source.
 void setValue(long value)
          Sets handle value of this pointer.
 void write(DataBuffer stackBuffer, int offset)
          Writes this parameter to a specified data source.
 
Methods inherited from class com.jniwrapper.Parameter
acceptIOPerformer, asReturnValue, equals, getAlignedLength, getBuffer, getOffset, indent, pop, push, read, setBuffer, toByteArray, write
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Pointer.Void

public Pointer.Void()
Constructs a new null pointer.


Pointer.Void

public Pointer.Void(long value)
Constructs a new void pointer that has the given value. Use this method for constructing special constants such as (HWND)-1.

Method Detail

getLength

public int getLength()
Description copied from class: Parameter
Returns a length of the parameter in memory. This method is analogous to C sizeof() operator.

Specified by:
getLength in class Parameter

write

public void write(DataBuffer stackBuffer,
                  int offset)
           throws MemoryAccessViolationException
Description copied from class: Parameter
Writes this parameter to a specified data source.

Specified by:
write in class Parameter
MemoryAccessViolationException

read

public void read(DataBuffer stackBuffer,
                 int offset)
          throws MemoryAccessViolationException
Description copied from class: Parameter
Reads this parameter from a specified data source.

Specified by:
read in class Parameter
MemoryAccessViolationException

clone

public java.lang.Object clone()
Specified by:
clone in class Parameter

setValue

public void setValue(long value)
Sets handle value of this pointer.


getValue

public long getValue()
Returns handle value of this object.


isNull

public boolean isNull()
Tests if this pointer is null.