|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object crystalspace.jbind.impl.csNativeObject
All crystal space Java wrapper which wrap a native object, subclass this class.
Field Summary | |
protected static csNOM |
ImplFactory
Get a reference to the Native Object Manager |
protected iPointer |
nPointer
This variable store the value of the native pointer |
Constructor Summary | |
csNativeObject(iPointer nPointer)
Create a java object which points to the native object nPointer. |
Method Summary | |
void |
changePointer(long nPointer)
This method permits to change the value of the pointer. |
boolean |
equals(java.lang.Object obj)
|
void |
finalize()
Finalize the java object, if memoryowner of the native pointer and the pointer is valid, delete the native object. |
long |
getPointer()
Return the value of the native pointer. |
static long |
getPointer(iPointer pointer)
Return the value of the pointer given as parameter. |
protected static long[] |
getPointerArray(iPointer[] pointerList)
|
int |
hashCode()
|
boolean |
isMemoryOwner()
Return true if java is responsible for deleting the native object. |
protected void |
isNativePointerValid()
Check if the native pointer is valid, if not it throws a NullPointerException. |
protected abstract boolean |
isNativePointerValidSafe(long pointer)
|
protected abstract void |
nDelete(long pointer)
|
protected static iPointer |
newNativeObject(long nativePointer,
iPointer caller,
java.lang.Class cClass)
This method create new native object or send back a reference of the caller. |
void |
setMemoryOwner(boolean owner)
If set to true - java will delete the native object when the java object is finalized. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
protected static csNOM ImplFactory
protected iPointer nPointer
Constructor Detail |
public csNativeObject(iPointer nPointer)
nPointer
- Method Detail |
public final void setMemoryOwner(boolean owner)
setMemoryOwner
in interface iPointer
owner
- iPointer.setMemoryOwner(boolean)
public final boolean isMemoryOwner()
isMemoryOwner
in interface iPointer
iPointer.isMemoryOwner()
public final void changePointer(long nPointer)
changePointer
in interface iPointer
nPointer
- iPointer.changePointer(long)
public final long getPointer()
getPointer
in interface iPointer
iPointer.getPointer()
public static final long getPointer(iPointer pointer)
pointer
-
public void finalize() throws java.lang.Throwable
java.lang.Throwable
Object.finalize()
protected abstract void nDelete(long pointer)
protected static iPointer newNativeObject(long nativePointer, iPointer caller, java.lang.Class cClass)
nativePointer
- caller
- cClass
-
protected void isNativePointerValid()
protected abstract boolean isNativePointerValidSafe(long pointer)
public int hashCode()
Object.hashCode()
public boolean equals(java.lang.Object obj)
Object.equals(java.lang.Object)
public java.lang.String toString()
Object.toString()
protected static long[] getPointerArray(iPointer[] pointerList)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |