sssd_dbus.h revision 8b8210c79b297b87e56d068e8839f7fe6755ab15
/*
SSSD
SSSD - D-BUS interface
Copyright (C) Stephen Gallagher 2008
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef _SSSD_DBUS_H_
#define _SSSD_DBUS_H_
struct sbus_conn_ctx;
DBusMessage **reply);
/*
* sbus_conn_destructor_fn
* Function to be called when a connection is finalized
*/
typedef int (*sbus_conn_destructor_fn)(
void *ctx);
/*
* sbus_server_conn_init_fn
* Set up function for connection-specific activities
* This function should define the sbus_conn_destructor_fn
* for this connection at a minimum
*/
typedef int (*sbus_server_conn_init_fn)(
struct sbus_conn_ctx *dct_ctx);
enum {
};
struct sbus_method {
const char *method;
};
struct sbus_method_ctx {
/*struct event_context *ev;*/
char *interface;
char *path;
/* If a non-default message_handler is desired, set it in this
* object before calling sbus_conn_add_method_ctx()
* Otherwise it will default to message_handler() in
*/
struct sbus_method *methods;
};
/* Server Functions */
int sbus_new_server(struct event_context *ev, struct sbus_method_ctx *ctx, const char *address, sbus_server_conn_init_fn init_fn);
/* Connection Functions */
struct sbus_conn_ctx **dct_ctx,
int sbus_default_connection_destructor(void *ctx);
#endif /* _SSSD_DBUS_H_*/