\hypertarget{dbus_8c}{}\doxysection{dbus.\+c File Reference}
\label{dbus_8c}\index{dbus.c@{dbus.c}}


I/O Adapter for D-\/\+Bus.  


{\ttfamily \#include $<$kdbhelper.\+h$>$}\newline
{\ttfamily \#include $<$kdbio/adapters/dbus.\+h$>$}\newline
{\ttfamily \#include $<$kdblogger.\+h$>$}\newline
{\ttfamily \#include $<$stdlib.\+h$>$}\newline
{\ttfamily \#include $<$string.\+h$>$}\newline
Include dependency graph for dbus.\+c\+:
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{dbus_8c__incl}
\end{center}
\end{figure}
\doxysubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{dbus_8h_ad2977d85dfa00a5dbc8e58b1a3a7f32e}{Elektra\+Io\+Adapter\+Dbus\+Handle}} $\ast$ \mbox{\hyperlink{dbus_8c_a0609e59502cc7169ac0512f780830831}{elektra\+Io\+Adapter\+Dbus\+Attach}} (DBus\+Connection $\ast$connection, \mbox{\hyperlink{kdbio_8h_aabcd87b8c09d4d4c1033fc1baa417391}{Elektra\+Io\+Interface}} $\ast$io\+Binding)
\begin{DoxyCompactList}\small\item\em Attach D-\/\+Bus connection to asynchronous I/O binding. \end{DoxyCompactList}\item 
int \mbox{\hyperlink{dbus_8c_aae9ed90d9c727532fe5b7753ab9b9576}{elektra\+Io\+Adapter\+Dbus\+Cleanup}} (\mbox{\hyperlink{dbus_8h_ad2977d85dfa00a5dbc8e58b1a3a7f32e}{Elektra\+Io\+Adapter\+Dbus\+Handle}} $\ast$priv)
\begin{DoxyCompactList}\small\item\em Remove D-\/\+Bus connection from I/O binding. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
I/O Adapter for D-\/\+Bus. 

\begin{DoxyCopyright}{Copyright}
BSD License (see LICENSE.\+md or \href{https://www.libelektra.org}{\texttt{ https\+://www.\+libelektra.\+org}}) 
\end{DoxyCopyright}


\doxysubsection{Function Documentation}
\mbox{\Hypertarget{dbus_8c_a0609e59502cc7169ac0512f780830831}\label{dbus_8c_a0609e59502cc7169ac0512f780830831}} 
\index{dbus.c@{dbus.c}!elektraIoAdapterDbusAttach@{elektraIoAdapterDbusAttach}}
\index{elektraIoAdapterDbusAttach@{elektraIoAdapterDbusAttach}!dbus.c@{dbus.c}}
\doxysubsubsection{\texorpdfstring{elektraIoAdapterDbusAttach()}{elektraIoAdapterDbusAttach()}}
{\footnotesize\ttfamily \mbox{\hyperlink{dbus_8h_ad2977d85dfa00a5dbc8e58b1a3a7f32e}{Elektra\+Io\+Adapter\+Dbus\+Handle}}$\ast$ elektra\+Io\+Adapter\+Dbus\+Attach (\begin{DoxyParamCaption}\item[{DBus\+Connection $\ast$}]{connection,  }\item[{\mbox{\hyperlink{kdbio_8h_aabcd87b8c09d4d4c1033fc1baa417391}{Elektra\+Io\+Interface}} $\ast$}]{io\+Binding }\end{DoxyParamCaption})}



Attach D-\/\+Bus connection to asynchronous I/O binding. 

Messages are sent and received using the I/O binding


\begin{DoxyParams}{Parameters}
{\em connection} & D-\/\+Bus connection \\
\hline
{\em io\+Binding} & I/O binding \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
handle to be used with \mbox{\hyperlink{dbus_8h_afb6f28b6454c0e09e5549cd4e785c341}{elektra\+Io\+Adapter\+Dbus\+Cleanup()}} or NULL on error 
\end{DoxyReturn}
\mbox{\Hypertarget{dbus_8c_aae9ed90d9c727532fe5b7753ab9b9576}\label{dbus_8c_aae9ed90d9c727532fe5b7753ab9b9576}} 
\index{dbus.c@{dbus.c}!elektraIoAdapterDbusCleanup@{elektraIoAdapterDbusCleanup}}
\index{elektraIoAdapterDbusCleanup@{elektraIoAdapterDbusCleanup}!dbus.c@{dbus.c}}
\doxysubsubsection{\texorpdfstring{elektraIoAdapterDbusCleanup()}{elektraIoAdapterDbusCleanup()}}
{\footnotesize\ttfamily int elektra\+Io\+Adapter\+Dbus\+Cleanup (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{dbus_8h_ad2977d85dfa00a5dbc8e58b1a3a7f32e}{Elektra\+Io\+Adapter\+Dbus\+Handle}} $\ast$}]{handle }\end{DoxyParamCaption})}



Remove D-\/\+Bus connection from I/O binding. 

This function frees the passed handle.

Currently it is NOT possible to revert all changes made to a connection by \mbox{\hyperlink{dbus_8h_a0609e59502cc7169ac0512f780830831}{elektra\+Io\+Adapter\+Dbus\+Attach()}}. It is advisable to call dbus\+\_\+connection\+\_\+unref() or dbus\+\_\+connection\+\_\+close() in case of a private bus connection afterwards.


\begin{DoxyParams}{Parameters}
{\em handle} & adapter handle \\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em 1} & on success \\
\hline
{\em 0} & on error \\
\hline
\end{DoxyRetVals}
