Class DoubleIEEE754
java.lang.Object
org.javagi.base.ProxyInstance
org.gnome.glib.DoubleIEEE754
- All Implemented Interfaces:
Proxy
The
GFloatIEEE754 and GDoubleIEEE754 unions are used to access the sign,
mantissa and exponent of IEEE floats and doubles. These unions are defined
as appropriate for a given platform. IEEE floats and doubles are supported
(used for storage) by at least Intel, PPC and Sparc.-
Constructor Summary
ConstructorsConstructorDescriptionAllocate a new DoubleIEEE754.DoubleIEEE754(double vDouble) Allocate a new DoubleIEEE754 with the fields set to the provided values.DoubleIEEE754(double vDouble, Arena arena) Allocate a new DoubleIEEE754 with the fields set to the provided values.DoubleIEEE754(Arena arena) Allocate a new DoubleIEEE754.DoubleIEEE754(MemorySegment address) Create a DoubleIEEE754 proxy instance for the provided memory address. -
Method Summary
Modifier and TypeMethodDescriptionstatic MemoryLayoutThe memory layout of the native struct.doubleRead the value of the fieldv_double.voidwriteVDouble(double vDouble) Write a value in the fieldv_double.Methods inherited from class ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
DoubleIEEE754
Create a DoubleIEEE754 proxy instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
DoubleIEEE754
Allocate a new DoubleIEEE754.- Parameters:
arena- to control the memory allocation scope
-
DoubleIEEE754
public DoubleIEEE754()Allocate a new DoubleIEEE754. The memory is allocated withArena.ofAuto(). -
DoubleIEEE754
Allocate a new DoubleIEEE754 with the fields set to the provided values.- Parameters:
vDouble- value for the fieldvDoublearena- to control the memory allocation scope
-
DoubleIEEE754
public DoubleIEEE754(double vDouble) Allocate a new DoubleIEEE754 with the fields set to the provided values. The memory is allocated withArena.ofAuto().- Parameters:
vDouble- value for the fieldvDouble
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readVDouble
public double readVDouble()Read the value of the fieldv_double.- Returns:
- The value of the field
v_double
-
writeVDouble
public void writeVDouble(double vDouble) Write a value in the fieldv_double.- Parameters:
vDouble- The new value for the fieldv_double
-