com.kenai.jaffl.struct
Class Struct.Pointer

java.lang.Object
  extended by java.lang.Number
      extended by com.kenai.jaffl.struct.Struct.NumberField
          extended by com.kenai.jaffl.struct.Struct.Pointer
All Implemented Interfaces:
Struct.Member, java.io.Serializable
Enclosing class:
Struct

public class Struct.Pointer
extends Struct.NumberField

Represents a native memory address.

See Also:
Serialized Form

Constructor Summary
Struct.Pointer()
          Creates a new Address field.
Struct.Pointer(Struct.Offset offset)
           
 
Method Summary
 Pointer get()
          Gets the com.googlecode.jffi.Address value from the native memory.
 int intValue()
          Returns an integer representation of this Pointer.
 long longValue()
          Returns an long representation of this Pointer.
 void set(java.lang.Number value)
          Sets the field to a new value.
 void set(Pointer value)
          Puts a com.googlecode.jffi.Address value into the native memory.
 int size()
          Gets the size of a Pointer in bits
 java.lang.String toString()
          Returns a string representation of this Pointer.
 
Methods inherited from class com.kenai.jaffl.struct.Struct.NumberField
doubleValue, floatValue, getMemoryIO, offset, struct
 
Methods inherited from class java.lang.Number
byteValue, shortValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Struct.Pointer

public Struct.Pointer()
Creates a new Address field.


Struct.Pointer

public Struct.Pointer(Struct.Offset offset)
Method Detail

get

public final Pointer get()
Gets the com.googlecode.jffi.Address value from the native memory.

Returns:
a com.googlecode.jffi.Address.

size

public final int size()
Gets the size of a Pointer in bits

Returns:
the size of the Pointer

set

public final void set(Pointer value)
Puts a com.googlecode.jffi.Address value into the native memory.


set

public void set(java.lang.Number value)
Description copied from class: Struct.NumberField
Sets the field to a new value.

Specified by:
set in class Struct.NumberField
Parameters:
value - The new value.

intValue

public final int intValue()
Returns an integer representation of this Pointer.

Specified by:
intValue in class java.lang.Number
Returns:
an integer value for this Pointer.

longValue

public final long longValue()
Returns an long representation of this Pointer.

Overrides:
longValue in class Struct.NumberField
Returns:
an long value for this Pointer.

toString

public final java.lang.String toString()
Returns a string representation of this Pointer.

Overrides:
toString in class Struct.NumberField
Returns:
a string representation of this Pointer.