napperley
08/25/2019, 4:14 AMpublic fun udev_list_entry_get_by_name(list_entry: kotlinx.cinterop.CValuesRef<cnames.structs.udev_list_entry>?, @kotlinx.cinterop.internal.CCall.CString name: kotlin.String?): kotlinx.cinterop.CPointer<cnames.structs.udev_list_entry>? { /* compiled code */ }
public fun udev_list_entry_get_name(list_entry: kotlinx.cinterop.CValuesRef<cnames.structs.udev_list_entry>?): kotlinx.cinterop.CPointer<kotlinx.cinterop.ByteVar /* = kotlinx.cinterop.ByteVarOf<kotlin.Byte> */>? { /* compiled code */ }
public fun udev_list_entry_get_next(list_entry: kotlinx.cinterop.CValuesRef<cnames.structs.udev_list_entry>?): kotlinx.cinterop.CPointer<cnames.structs.udev_list_entry>? { /* compiled code */ }
public fun udev_list_entry_get_value(list_entry: kotlinx.cinterop.CValuesRef<cnames.structs.udev_list_entry>?): kotlinx.cinterop.CPointer<kotlinx.cinterop.ByteVar /* = kotlinx.cinterop.ByteVarOf<kotlin.Byte> */>? { /* compiled code */ }
There doesn't appear to be a definition in any of the knm files for udev_list_entry
(a C struct), however cnames.structs.udev_list_entry
does exist but its definition doesn't seem to appear in any of the knm files which is strange.msink
08/25/2019, 4:57 AMlibudev.h
it just declared as opaque handle struct udev_list_entry;
, and defined in libudev-internal.h
So if you want to access it's fields - add libudev-internal.h
to headers in .def
filenapperley
08/25/2019, 5:26 AMnapperley
08/25/2019, 5:34 AMmsink
08/25/2019, 5:38 AMmsink
08/25/2019, 6:28 AMnapperley
08/25/2019, 6:52 AMnapperley
08/25/2019, 6:53 AMolonho
08/25/2019, 8:02 AMstruct Foo
in C header, and is common way if declaring opaque handle type. It could be used from K/N same way as from C.olonho
08/25/2019, 8:03 AM---
.