Package org.gnome.gobject
Class FlagsClass
java.lang.Object
io.github.jwharm.javagi.base.ProxyInstance
org.gnome.gobject.FlagsClass
- All Implemented Interfaces:
Proxy
The class of a flags type holds information about its
possible values.
-
Constructor Summary
ConstructorDescriptionAllocate a new FlagsClass.FlagsClass
(Arena arena) Allocate a new FlagsClass.FlagsClass
(MemorySegment address) Create a FlagsClass proxy instance for the provided memory address.FlagsClass
(TypeClass gTypeClass, int mask, int nValues, FlagsValue values) Allocate a new FlagsClass with the fields set to the provided values.FlagsClass
(TypeClass gTypeClass, int mask, int nValues, FlagsValue values, Arena arena) Allocate a new FlagsClass with the fields set to the provided values. -
Method Summary
Modifier and TypeMethodDescriptionstatic MemoryLayout
The memory layout of the native struct.Read the value of the fieldg_type_class
.int
readMask()
Read the value of the fieldmask
.int
Read the value of the fieldn_values
.Read the value of the fieldvalues
.void
writeGTypeClass
(TypeClass gTypeClass) Write a value in the fieldg_type_class
.void
writeMask
(int mask) Write a value in the fieldmask
.void
writeNValues
(int nValues) Write a value in the fieldn_values
.void
writeValues
(FlagsValue values) Write a value in the fieldvalues
.Methods inherited from class io.github.jwharm.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
FlagsClass
Create a FlagsClass proxy instance for the provided memory address.- Parameters:
address
- the memory address of the native object
-
FlagsClass
Allocate a new FlagsClass.- Parameters:
arena
- to control the memory allocation scope
-
FlagsClass
public FlagsClass()Allocate a new FlagsClass. The memory is allocated withArena.ofAuto()
. -
FlagsClass
Allocate a new FlagsClass with the fields set to the provided values.- Parameters:
gTypeClass
- value for the fieldgTypeClass
mask
- value for the fieldmask
nValues
- value for the fieldnValues
values
- value for the fieldvalues
arena
- to control the memory allocation scope
-
FlagsClass
Allocate a new FlagsClass with the fields set to the provided values. The memory is allocated withArena.ofAuto()
.- Parameters:
gTypeClass
- value for the fieldgTypeClass
mask
- value for the fieldmask
nValues
- value for the fieldnValues
values
- value for the fieldvalues
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readGTypeClass
Read the value of the fieldg_type_class
.- Returns:
- The value of the field
g_type_class
-
writeGTypeClass
Write a value in the fieldg_type_class
.- Parameters:
gTypeClass
- The new value for the fieldg_type_class
-
readMask
public int readMask()Read the value of the fieldmask
.- Returns:
- The value of the field
mask
-
writeMask
public void writeMask(int mask) Write a value in the fieldmask
.- Parameters:
mask
- The new value for the fieldmask
-
readNValues
public int readNValues()Read the value of the fieldn_values
.- Returns:
- The value of the field
n_values
-
writeNValues
public void writeNValues(int nValues) Write a value in the fieldn_values
.- Parameters:
nValues
- The new value for the fieldn_values
-
readValues
Read the value of the fieldvalues
.- Returns:
- The value of the field
values
-
writeValues
Write a value in the fieldvalues
.- Parameters:
values
- The new value for the fieldvalues
-