Fcitx
Classes | Macros | Typedefs | Enumerations | Functions
objectvtable.h File Reference

High level API for dbus objects. More...

#include <cstdint>
#include <exception>
#include <functional>
#include <memory>
#include <mutex>
#include <string>
#include <tuple>
#include <type_traits>
#include <fcitx-utils/dbus/message.h>
#include <fcitx-utils/fcitxutils_export.h>
#include <fcitx-utils/flags.h>
#include <fcitx-utils/macros.h>
#include <fcitx-utils/trackableobject.h>
Include dependency graph for objectvtable.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  fcitx::dbus::MethodCallError
 An exception if you want message to return a DBus error. More...
 
class  fcitx::dbus::ObjectVTableMethod
 Register a DBus method to current DBus VTable. More...
 
struct  fcitx::dbus::ReturnValueHelper< T >
 
struct  fcitx::dbus::ReturnValueHelper< void >
 
class  fcitx::dbus::ObjectVTableSignal
 Register a DBus signal to current DBus VTable. More...
 
class  fcitx::dbus::ObjectVTableProperty
 Register a DBus read-only property to current DBus VTable. More...
 
class  fcitx::dbus::ObjectVTableWritableProperty
 Register a DBus property to current DBus VTable. More...
 
class  fcitx::dbus::ObjectVTableBase
 
class  fcitx::dbus::ObjectVTable< T >
 Base class of any DBus object. More...
 
class  fcitx::dbus::ObjectVTablePropertyObjectMethodAdaptor< Ret, Args, Callback >
 
class  fcitx::dbus::ObjectVTablePropertyGetMethodAdaptor< Ret, Callback >
 
class  fcitx::dbus::ObjectVTablePropertySetMethodAdaptor< Ret, Callback >
 

Macros

#define FCITX_OBJECT_VTABLE_METHOD(FUNCTION, FUNCTION_NAME, SIGNATURE, RET)
 Register a class member function as a DBus method. More...
 
#define FCITX_OBJECT_VTABLE_SIGNAL(SIGNAL, SIGNAL_NAME, SIGNATURE)
 Register a new DBus signal. More...
 
#define FCITX_OBJECT_VTABLE_PROPERTY(PROPERTY, NAME, SIGNATURE, GETMETHOD, ...)
 Register a new DBus read-only property. More...
 
#define FCITX_OBJECT_VTABLE_WRITABLE_PROPERTY(PROPERTY, NAME, SIGNATURE, GETMETHOD, SETMETHOD, ...)
 Register a new DBus read-only property. More...
 

Typedefs

using fcitx::dbus::ObjectMethod = std::function< bool(Message)>
 
using fcitx::dbus::ObjectMethodClosure = std::function< bool(Message, const ObjectMethod &)>
 
using fcitx::dbus::PropertyGetMethod = std::function< void(Message &)>
 
using fcitx::dbus::PropertySetMethod = std::function< bool(Message &)>
 
using fcitx::dbus::PropertyOptions = Flags< PropertyOption >
 

Enumerations

enum  PropertyOption : uint32_t { Hidden = (1 << 0) }
 

Functions

template<typename Ret , typename Args , typename Callback >
auto fcitx::dbus::makeObjectVTablePropertyObjectMethodAdaptor (ObjectVTableBase *base, Callback &&callback)
 
template<typename Ret , typename Callback >
auto fcitx::dbus::makeObjectVTablePropertyGetMethodAdaptor (ObjectVTableBase *base, Callback &&callback)
 
template<typename Ret , typename Callback >
auto fcitx::dbus::makeObjectVTablePropertySetMethodAdaptor (ObjectVTableBase *base, Callback &&callback)
 

Detailed Description

High level API for dbus objects.

Definition in file objectvtable.h.