Kanzi  3.9.9
Kanzi Engine C++ API
kanzi::wayland::WaylandRegistry Class Reference

Wayland registry wrapper class. More...

#include <kanzi/core.ui/platform/windowing_ng/wayland/wayland_registry.hpp>

Inheritance diagram for kanzi::wayland::WaylandRegistry:
[legend]

Public Member Functions

KZ_NO_DISCARD void * bind (const wl_interface *interface, unsigned int registerName, unsigned int version) const noexcept
 Bind an interface to the display. More...
 
template<typename T >
KZ_NO_DISCARDbindTo (const wl_interface *interface, unsigned int registerName, unsigned int version) const noexcept
 Bind and interface to the display and cast to the correct type. More...
 
 WaylandRegistry (wl_registry *nativeHandle) noexcept
 Constructor. More...
 
 WaylandRegistry (const WaylandDisplay &waylandDisplay) noexcept
 Constructor. More...
 
- Public Member Functions inherited from kanzi::wayland::WaylandInterface< WaylandRegistry, wl_registry, wl_registry_listener >
bool addListener (enable_if_t<!is_same< L, void >::value, const L & > listener, void *data) const noexcept
 Adds a listener to Wayland object. More...
 
KZ_NO_DISCARD unsigned int askVersion () const noexcept
 Requests compositor which interface version we use. More...
 
KZ_NO_DISCARD wl_registry * getNativeHandle () const noexcept
 Gets the underlying native handle. More...
 

Static Public Attributes

static const wl_interface s_nativeInterface
 Represents the underlying native interface. More...
 

Additional Inherited Members

- Public Types inherited from kanzi::wayland::WaylandInterface< WaylandRegistry, wl_registry, wl_registry_listener >
using ListenerType = wl_registry_listener
 Generic alias to query for appropriate listener type. More...
 
- Static Public Member Functions inherited from kanzi::wayland::WaylandInterface< WaylandRegistry, wl_registry, wl_registry_listener >
static KZ_NO_DISCARD unsigned int askVersion (wl_registry *handle) noexcept
 Requests compositor which interface version we use. More...
 

Detailed Description

Wayland registry wrapper class.

Since
Kanzi 3.9.8

Constructor & Destructor Documentation

kanzi::wayland::WaylandRegistry::WaylandRegistry ( wl_registry *  nativeHandle)
explicitnoexcept

Constructor.

Parameters
nativeHandleNative Wayland handle.
kanzi::wayland::WaylandRegistry::WaylandRegistry ( const WaylandDisplay waylandDisplay)
explicitnoexcept

Constructor.

Parameters
waylandDisplayWaylandDisplay to construct WaylandRegistry from.

Member Function Documentation

KZ_NO_DISCARD void* kanzi::wayland::WaylandRegistry::bind ( const wl_interface *  interface,
unsigned int  registerName,
unsigned int  version 
) const
noexcept

Bind an interface to the display.

Parameters
interfaceInterface to bind.
registerNameUnique numeric name of the interface.
versionVersion of the interface to request.
Returns
Handle to the bound interface.
template<typename T >
KZ_NO_DISCARD T kanzi::wayland::WaylandRegistry::bindTo ( const wl_interface *  interface,
unsigned int  registerName,
unsigned int  version 
) const
inlinenoexcept

Bind and interface to the display and cast to the correct type.

Prefer using this function instead of bind() because it casts handle to the specified type.

See also
bind()
Template Parameters
TWayland type to which to cast handle.
Parameters
interfaceInterface to bind.
registerNameUnique numeric name of the interface.
versionVersion of the interface to request.
Returns
Handle to the bound interface.

Member Data Documentation

const wl_interface kanzi::wayland::WaylandRegistry::s_nativeInterface
static

Represents the underlying native interface.


The documentation for this class was generated from the following file: