Package de.intarsys.nativec.type
Class NativeLong
java.lang.Object
de.intarsys.nativec.type.NativeObject
de.intarsys.nativec.type.NativeSimple
de.intarsys.nativec.type.NativeNumber
de.intarsys.nativec.type.NativeLong
- All Implemented Interfaces:
INativeObject
A wrapper for a primitive long. The size of a long depends on the platform;
on a 64-bit Linux or Mac OS X we have 8 byte longs...
-
Field Summary
FieldsFields 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
ConstructorsModifierConstructorDescriptionCreate a new wrapperNativeLong
(long value) Create a new wrapperprotected
NativeLong
(INativeHandle handle) -
Method Summary
Modifier and TypeMethodDescriptionbyte
This as a java primitive byte value.static NativeLong
createFromAddress
(long address) The meta information and behavior for the NativeObject.getValue()
A Java side representation from the memory.int
intValue()
This as a java primitive int value.long
This as a java primitive long value.void
setValue
(long value) void
Assign (and marshall to memory) the Java side representation.short
This as a java primitive short value.toString()
Methods inherited from class de.intarsys.nativec.type.NativeSimple
getByteCount
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 Details
-
META
The meta class instance
-
-
Constructor Details
-
NativeLong
public NativeLong()Create a new wrapper -
NativeLong
-
NativeLong
public NativeLong(long value) Create a new wrapper
-
-
Method Details
-
createFromAddress
-
byteValue
public byte byteValue()Description copied from class:NativeNumber
This as a java primitive byte value.- Specified by:
byteValue
in classNativeNumber
- Returns:
- This as a java primitive byte value.
-
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
Description copied from interface:INativeObject
A Java side representation from the memory.- Returns:
- A Java side representation for the
INativeObject
.
-
intValue
public int intValue()Description copied from class:NativeNumber
This as a java primitive int value.- Specified by:
intValue
in classNativeNumber
- Returns:
- This as a java primitive int value.
-
longValue
public long longValue()Description copied from class:NativeNumber
This as a java primitive long value.- Specified by:
longValue
in classNativeNumber
- Returns:
- This as a java primitive long value.
-
setValue
public void setValue(long value) -
setValue
Description copied from interface:INativeObject
Assign (and marshall to memory) the Java side representation.- Parameters:
value
- The new Java value.
-
shortValue
public short shortValue()Description copied from class:NativeNumber
This as a java primitive short value.- Specified by:
shortValue
in classNativeNumber
- Returns:
- This as a java primitive short value.
-
toString
-