JNative project : see http://jnative.sf.net


org.xvolks.jnative.misc.basicStructures
Interface BasicData<T>

All Known Implementing Classes:
AbstractBasicData, HWND, INT64, LONG, LPARAM, LRESULT, MemoryStatusEx, MSG, Point, UINT, WPARAM

public interface BasicData<T>

$Id: BasicData.java,v 1.3 2006/01/14 19:27:01 mdenty Exp $

Instances of BasicData are specialized blocks of memory

They are values, memory, pointers to the memory

This software is released under the GPL.


Method Summary
 Pointer createPointer()
          Method createPointer reserves a native MemoryBlock and copy its value in it
 Pointer getPointer()
          Method getPointer gets the Pointer created by createPointer()
 int getSizeOf()
          Method getSizeOf
 T getValue()
          Method getValue gets the value of this BasicData (often this)
 T getValueFromPointer()
          Method getValueFromPointer gets the value of this data from the native memory block
 

Method Detail

getValue

T getValue()
Method getValue gets the value of this BasicData (often this)

Returns:
a T

getValueFromPointer

T getValueFromPointer()
                      throws NativeException
Method getValueFromPointer gets the value of this data from the native memory block

Returns:
a T
Throws:
NativeException

getPointer

Pointer getPointer()
Method getPointer gets the Pointer created by createPointer()

Returns:
a Pointer the pointer or null if createPointer() was not called

getSizeOf

int getSizeOf()
Method getSizeOf

Returns:
the size of this data

createPointer

Pointer createPointer()
                      throws NativeException
Method createPointer reserves a native MemoryBlock and copy its value in it

Returns:
a Pointer on the reserved memory
Throws:
NativeException

JNative project : see http://jnative.sf.net