Package de.intarsys.nativec.type
Class NativeReference
- java.lang.Object
-
- de.intarsys.nativec.type.NativeObject
-
- de.intarsys.nativec.type.NativeReference
-
- All Implemented Interfaces:
INativeObject
public class NativeReference extends NativeObject
An object representing a reference to another object ("pointer").
-
-
Field Summary
Fields Modifier and Type Field Description static NativeReferenceType
META
The meta class instance-
Fields inherited from class de.intarsys.nativec.type.NativeObject
DEBUG, handle, SHIFT_INT, SHIFT_LONG, SHIFT_LONGLONG, SIZE_BYTE, SIZE_INT, SIZE_LONG, SIZE_LONGLONG, SIZE_PTR, SIZE_SHORT
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
NativeReference(NativeReferenceType type)
protected
NativeReference(NativeReferenceType type, INativeHandle handle)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static NativeReference
create(INativeType baseType)
INativeType
getBaseType()
int
getByteCount()
The number of bytes occupied by this.INativeType
getNativeType()
The meta information and behavior for the NativeObject.java.lang.Object
getValue()
A Java side representation from the memory.void
setBaseType(INativeType baseType)
void
setValue(java.lang.Object value)
Assign (and marshall to memory) the Java side representation.-
Methods inherited from class de.intarsys.nativec.type.NativeObject
allocate, cast, createReference, getByte, getByteArray, getBytes, getCLong, getInt, getNativeHandle, getNativeHandle, getShort, getString, getWideString, isNull, setByte, setByteArray, setCLong, setInt, setNativeHandle, setShort, setString, setWideString, toNestedString
-
-
-
-
Field Detail
-
META
public static final NativeReferenceType META
The meta class instance
-
-
Constructor Detail
-
NativeReference
protected NativeReference(NativeReferenceType type)
-
NativeReference
protected NativeReference(NativeReferenceType type, INativeHandle handle)
-
-
Method Detail
-
create
public static NativeReference create(INativeType baseType)
-
getBaseType
public INativeType getBaseType()
-
getByteCount
public int getByteCount()
Description copied from class:NativeObject
The number of bytes occupied by this.- Specified by:
getByteCount
in classNativeObject
- Returns:
- The number of bytes occupied by this.
-
getNativeType
public INativeType getNativeType()
Description copied from class:NativeObject
The meta information and behavior for the NativeObject.There is exactly one meta instance for all NativeObject instances of a certain type.
- Specified by:
getNativeType
in interfaceINativeObject
- Specified by:
getNativeType
in classNativeObject
- Returns:
- The meta information and behavior for the NativeObject.
-
getValue
public java.lang.Object getValue()
Description copied from interface:INativeObject
A Java side representation from the memory.- Returns:
- A Java side representation for the
INativeObject
.
-
setBaseType
public void setBaseType(INativeType baseType)
-
setValue
public void setValue(java.lang.Object value)
Description copied from interface:INativeObject
Assign (and marshall to memory) the Java side representation.- Parameters:
value
- The new Java value.
-
-