Package org.gnome.gobject
Class FlagsClass
java.lang.Object
org.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
ConstructorsConstructorDescriptionAllocate 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 MemoryLayoutThe memory layout of the native struct.@Nullable TypeClassRead the value of the fieldg_type_class.intreadMask()Read the value of the fieldmask.intRead the value of the fieldn_values.Read the value of the fieldvalues.voidwriteGTypeClass(@Nullable TypeClass gTypeClass) Write a value in the fieldg_type_class.voidwriteMask(int mask) Write a value in the fieldmask.voidwriteNValues(int nValues) Write a value in the fieldn_values.voidwriteValues(FlagsValue values) Write a value in the fieldvalues.Methods inherited from class org.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 fieldgTypeClassmask- value for the fieldmasknValues- value for the fieldnValuesvalues- value for the fieldvaluesarena- 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 fieldgTypeClassmask- value for the fieldmasknValues- value for the fieldnValuesvalues- 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
-