Class DBusInterfaceInfo

java.lang.Object
org.javagi.base.ProxyInstance
org.gnome.gio.DBusInterfaceInfo
All Implemented Interfaces:
Proxy

@Generated("org.javagi.JavaGI") public class DBusInterfaceInfo extends ProxyInstance
Information about a D-Bus interface.
Since:
2.26
  • Constructor Details

    • DBusInterfaceInfo

      public DBusInterfaceInfo(MemorySegment address)
      Create a DBusInterfaceInfo proxy instance for the provided memory address.
      Parameters:
      address - the memory address of the native object
    • DBusInterfaceInfo

      public DBusInterfaceInfo(Arena arena)
      Allocate a new DBusInterfaceInfo.
      Parameters:
      arena - to control the memory allocation scope
    • DBusInterfaceInfo

      public DBusInterfaceInfo()
      Allocate a new DBusInterfaceInfo. The memory is allocated with Arena.ofAuto().
    • DBusInterfaceInfo

      public DBusInterfaceInfo(int refCount, String name, DBusMethodInfo[] methods, DBusSignalInfo[] signals, DBusPropertyInfo[] properties, DBusAnnotationInfo[] annotations, Arena arena)
      Allocate a new DBusInterfaceInfo with the fields set to the provided values.
      Parameters:
      refCount - value for the field refCount
      name - value for the field name
      methods - value for the field methods
      signals - value for the field signals
      properties - value for the field properties
      annotations - value for the field annotations
      arena - to control the memory allocation scope
    • DBusInterfaceInfo

      public DBusInterfaceInfo(int refCount, String name, DBusMethodInfo[] methods, DBusSignalInfo[] signals, DBusPropertyInfo[] properties, DBusAnnotationInfo[] annotations)
      Allocate a new DBusInterfaceInfo with the fields set to the provided values. The memory is allocated with Arena.ofAuto().
      Parameters:
      refCount - value for the field refCount
      name - value for the field name
      methods - value for the field methods
      signals - value for the field signals
      properties - value for the field properties
      annotations - value for the field annotations
  • Method Details

    • getType

      public static @Nullable Type getType()
      Get the GType of the DBusInterfaceInfo class.
      Returns:
      the GType
    • getMemoryLayout

      public static MemoryLayout getMemoryLayout()
      The memory layout of the native struct.
      Returns:
      the memory layout
    • readRefCount

      public int readRefCount()
      Read the value of the field ref_count.
      Returns:
      The value of the field ref_count
    • writeRefCount

      public void writeRefCount(int refCount)
      Write a value in the field ref_count.
      Parameters:
      refCount - The new value for the field ref_count
    • readName

      public String readName()
      Read the value of the field name.
      Returns:
      The value of the field name
    • writeName

      public void writeName(String name, Arena _arena)
      Write a value in the field name.
      Parameters:
      name - The new value for the field name
      _arena - to control the memory allocation scope
    • readMethods

      public @Nullable DBusMethodInfo @Nullable [] readMethods()
      Read the value of the field methods.
      Returns:
      The value of the field methods
    • writeMethods

      public void writeMethods(@Nullable DBusMethodInfo @Nullable [] methods, Arena _arena)
      Write a value in the field methods.
      Parameters:
      methods - The new value for the field methods
      _arena - to control the memory allocation scope
    • readSignals

      public @Nullable DBusSignalInfo @Nullable [] readSignals()
      Read the value of the field signals.
      Returns:
      The value of the field signals
    • writeSignals

      public void writeSignals(@Nullable DBusSignalInfo @Nullable [] signals, Arena _arena)
      Write a value in the field signals.
      Parameters:
      signals - The new value for the field signals
      _arena - to control the memory allocation scope
    • readProperties

      public @Nullable DBusPropertyInfo @Nullable [] readProperties()
      Read the value of the field properties.
      Returns:
      The value of the field properties
    • writeProperties

      public void writeProperties(@Nullable DBusPropertyInfo @Nullable [] properties, Arena _arena)
      Write a value in the field properties.
      Parameters:
      properties - The new value for the field properties
      _arena - to control the memory allocation scope
    • readAnnotations

      public @Nullable DBusAnnotationInfo @Nullable [] readAnnotations()
      Read the value of the field annotations.
      Returns:
      The value of the field annotations
    • writeAnnotations

      public void writeAnnotations(@Nullable DBusAnnotationInfo @Nullable [] annotations, Arena _arena)
      Write a value in the field annotations.
      Parameters:
      annotations - The new value for the field annotations
      _arena - to control the memory allocation scope
    • cacheBuild

      public void cacheBuild()

      Builds a lookup-cache to speed up g_dbus_interface_info_lookup_method(), g_dbus_interface_info_lookup_signal() and g_dbus_interface_info_lookup_property().

      If this has already been called with info, the existing cache is used and its use count is increased.

      Note that this DBusInterfaceInfo cannot be modified until g_dbus_interface_info_cache_release() is called.

      Since:
      2.30
    • cacheRelease

      public void cacheRelease()
      Decrements the usage count for the cache for this DBusInterfaceInfo built by g_dbus_interface_info_cache_build() (if any) and frees the resources used by the cache if the usage count drops to zero.
      Since:
      2.30
    • generateXml

      public void generateXml(int indent, String stringBuilder)

      Appends an XML representation of this DBusInterfaceInfo (and its children) to stringBuilder.

      This function is typically used for generating introspection XML documents at run-time for handling the org.freedesktop.DBus.Introspectable.Introspect method.

      Parameters:
      indent - Indentation level.
      stringBuilder - A GString to to append XML data to.
      Since:
      2.26
    • lookupMethod

      public @Nullable DBusMethodInfo lookupMethod(String name)

      Looks up information about a method.

      The cost of this function is O(n) in number of methods unless g_dbus_interface_info_cache_build() has been used on info.

      Parameters:
      name - A D-Bus method name (typically in CamelCase)
      Returns:
      A GDBusMethodInfo or null if not found. Do not free, it is owned by info.
      Since:
      2.26
    • lookupProperty

      public @Nullable DBusPropertyInfo lookupProperty(String name)

      Looks up information about a property.

      The cost of this function is O(n) in number of properties unless g_dbus_interface_info_cache_build() has been used on info.

      Parameters:
      name - A D-Bus property name (typically in CamelCase).
      Returns:
      A GDBusPropertyInfo or null if not found. Do not free, it is owned by info.
      Since:
      2.26
    • lookupSignal

      public @Nullable DBusSignalInfo lookupSignal(String name)

      Looks up information about a signal.

      The cost of this function is O(n) in number of signals unless g_dbus_interface_info_cache_build() has been used on info.

      Parameters:
      name - A D-Bus signal name (typically in CamelCase)
      Returns:
      A GDBusSignalInfo or null if not found. Do not free, it is owned by info.
      Since:
      2.26
    • ref

      public DBusInterfaceInfo ref()
      If this DBusInterfaceInfo is statically allocated does nothing. Otherwise increases the reference count.
      Returns:
      The same info.
      Since:
      2.26
    • unref

      public void unref()
      If this DBusInterfaceInfo is statically allocated, does nothing. Otherwise decreases the reference count of info. When its reference count drops to 0, the memory used is freed.
      Since:
      2.26