dbus-shared.h

00001 /* -*- mode: C; c-file-style: "gnu"; indent-tabs-mode: nil; -*- */
00002 /* dbus-shared.h  Stuff used by both dbus/dbus.h low-level and C/C++ binding APIs
00003  *
00004  * Copyright (C) 2004 Red Hat, Inc.
00005  *
00006  * Licensed under the Academic Free License version 2.1
00007  * 
00008  * This program is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * This program is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  * 
00018  * You should have received a copy of the GNU General Public License
00019  * along with this program; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  */
00023 
00024 #ifndef DBUS_SHARED_H
00025 #define DBUS_SHARED_H
00026 
00027 /* Don't include anything in here from anywhere else. It's
00028  * intended for use by any random library.
00029  */
00030 
00031 #ifdef  __cplusplus
00032 extern "C" {
00033 #if 0
00034 } /* avoids confusing emacs indentation */
00035 #endif
00036 #endif
00037 
00038 /* Normally docs are in .c files, but there isn't a .c file for this. */
00056 typedef enum
00057 {
00058   DBUS_BUS_SESSION,    
00059   DBUS_BUS_SYSTEM,     
00060   DBUS_BUS_STARTER     
00061 } DBusBusType;
00062 
00066 typedef enum
00067 {
00068   DBUS_HANDLER_RESULT_HANDLED,         
00069   DBUS_HANDLER_RESULT_NOT_YET_HANDLED, 
00070   DBUS_HANDLER_RESULT_NEED_MEMORY      
00071 } DBusHandlerResult;
00072 
00073 /* Bus names */
00074 
00076 #define DBUS_SERVICE_DBUS      "org.freedesktop.DBus"
00077 
00078 /* Paths */
00080 #define DBUS_PATH_DBUS  "/org/freedesktop/DBus"
00081 
00082 #define DBUS_PATH_LOCAL "/org/freedesktop/DBus/Local"
00083 
00084 /* Interfaces, these #define don't do much other than
00085  * catch typos at compile time
00086  */
00088 #define DBUS_INTERFACE_DBUS           "org.freedesktop.DBus"
00089 
00090 #define DBUS_INTERFACE_INTROSPECTABLE "org.freedesktop.DBus.Introspectable"
00091 
00092 #define DBUS_INTERFACE_PROPERTIES     "org.freedesktop.DBus.Properties"
00093 
00094 #define DBUS_INTERFACE_PEER           "org.freedesktop.DBus.Peer"
00095 
00100 #define DBUS_INTERFACE_LOCAL "org.freedesktop.DBus.Local"
00101 
00102 /* Owner flags */
00103 #define DBUS_NAME_FLAG_ALLOW_REPLACEMENT 0x1 
00104 #define DBUS_NAME_FLAG_REPLACE_EXISTING  0x2 
00105 #define DBUS_NAME_FLAG_DO_NOT_QUEUE      0x4 
00107 /* Replies to request for a name */
00108 #define DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER  1 
00109 #define DBUS_REQUEST_NAME_REPLY_IN_QUEUE       2 
00110 #define DBUS_REQUEST_NAME_REPLY_EXISTS         3 
00111 #define DBUS_REQUEST_NAME_REPLY_ALREADY_OWNER  4 
00113 /* Replies to releasing a name */
00114 #define DBUS_RELEASE_NAME_REPLY_RELEASED        1 
00115 #define DBUS_RELEASE_NAME_REPLY_NON_EXISTENT    2 
00116 #define DBUS_RELEASE_NAME_REPLY_NOT_OWNER       3 
00118 /* Replies to service starts */
00119 #define DBUS_START_REPLY_SUCCESS         1 
00120 #define DBUS_START_REPLY_ALREADY_RUNNING 2 
00124 #ifdef __cplusplus
00125 #if 0
00126 { /* avoids confusing emacs indentation */
00127 #endif
00128 }
00129 #endif
00130 
00131 #endif /* DBUS_SHARED_H */

Generated on Tue Feb 24 16:40:40 2009 for D-Bus by  doxygen 1.5.1