Package org.gnome.glib
Class TestLogMsg
java.lang.Object
org.javagi.base.ProxyInstance
org.gnome.glib.TestLogMsg
- All Implemented Interfaces:
Proxy
-
Constructor Summary
ConstructorsConstructorDescriptionAllocate a new TestLogMsg.TestLogMsg(Arena arena) Allocate a new TestLogMsg.TestLogMsg(MemorySegment address) Create a TestLogMsg proxy instance for the provided memory address.TestLogMsg(TestLogType logType, int nStrings, String[] strings, int nNums, MemorySegment nums) Allocate a new TestLogMsg with the fields set to the provided values.TestLogMsg(TestLogType logType, int nStrings, String[] strings, int nNums, MemorySegment nums, Arena arena) Allocate a new TestLogMsg with the fields set to the provided values. -
Method Summary
Modifier and TypeMethodDescriptionvoidfree()Internal function for gtester to free test log messages, no ABI guarantees provided.static MemoryLayoutThe memory layout of the native struct.Read the value of the fieldlog_type.intRead the value of the fieldn_nums.intRead the value of the fieldn_strings.readNums()Read the value of the fieldnums.String[]readStrings(int length) Read the value of the fieldstrings.voidwriteLogType(TestLogType logType) Write a value in the fieldlog_type.voidwriteNNums(int nNums) Write a value in the fieldn_nums.voidwriteNStrings(int nStrings) Write a value in the fieldn_strings.voidwriteNums(MemorySegment nums) Write a value in the fieldnums.voidwriteStrings(String[] strings, Arena _arena) Write a value in the fieldstrings.Methods inherited from class org.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
TestLogMsg
Create a TestLogMsg proxy instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
TestLogMsg
Allocate a new TestLogMsg.- Parameters:
arena- to control the memory allocation scope
-
TestLogMsg
public TestLogMsg()Allocate a new TestLogMsg. The memory is allocated withArena.ofAuto(). -
TestLogMsg
public TestLogMsg(TestLogType logType, int nStrings, String[] strings, int nNums, MemorySegment nums, Arena arena) Allocate a new TestLogMsg with the fields set to the provided values.- Parameters:
logType- value for the fieldlogTypenStrings- value for the fieldnStringsstrings- value for the fieldstringsnNums- value for the fieldnNumsnums- value for the fieldnumsarena- to control the memory allocation scope
-
TestLogMsg
public TestLogMsg(TestLogType logType, int nStrings, String[] strings, int nNums, MemorySegment nums) Allocate a new TestLogMsg with the fields set to the provided values. The memory is allocated withArena.ofAuto().- Parameters:
logType- value for the fieldlogTypenStrings- value for the fieldnStringsstrings- value for the fieldstringsnNums- value for the fieldnNumsnums- value for the fieldnums
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readLogType
Read the value of the fieldlog_type.- Returns:
- The value of the field
log_type
-
writeLogType
Write a value in the fieldlog_type.- Parameters:
logType- The new value for the fieldlog_type
-
readNStrings
public int readNStrings()Read the value of the fieldn_strings.- Returns:
- The value of the field
n_strings
-
writeNStrings
public void writeNStrings(int nStrings) Write a value in the fieldn_strings.- Parameters:
nStrings- The new value for the fieldn_strings
-
readStrings
Read the value of the fieldstrings.- Parameters:
length- the number ofstringsto read@return The value of the fieldstrings
-
writeStrings
-
readNNums
public int readNNums()Read the value of the fieldn_nums.- Returns:
- The value of the field
n_nums
-
writeNNums
public void writeNNums(int nNums) Write a value in the fieldn_nums.- Parameters:
nNums- The new value for the fieldn_nums
-
readNums
Read the value of the fieldnums.- Returns:
- The value of the field
nums
-
writeNums
Write a value in the fieldnums.- Parameters:
nums- The new value for the fieldnums
-
free
public void free()Internal function for gtester to free test log messages, no ABI guarantees provided.
-