dbus-server.inc 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. { -*- mode: C; c-file-style: "gnu" -*- }
  2. { dbus-server.h DBusServer object
  3. *
  4. * Copyright (C) 2002, 2003 Red Hat Inc.
  5. *
  6. * Licensed under the Academic Free License version 2.1
  7. *
  8. * This program is free software; you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation; either version 2 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program; if not, write to the Free Software
  20. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  21. *
  22. }
  23. {#include <dbus/dbus-errors.h>
  24. #include <dbus/dbus-message.h>
  25. #include <dbus/dbus-connection.h>
  26. #include <dbus/dbus-protocol.h>}
  27. type
  28. DBusServer = record end;
  29. PDBusServer = ^DBusServer;
  30. DBusNewConnectionFunction = procedure (server: PDBusServer;
  31. new_connection: PDBusConnection; data: Pointer);
  32. function dbus_server_listen(const address: PChar; error: PDBusError): PDBusServer; cdecl; external LibDBus;
  33. function dbus_server_ref(error: PDBusError): PDBusServer; cdecl; external LibDBus;
  34. procedure dbus_server_unref(error: PDBusError); cdecl; external LibDBus;
  35. procedure dbus_server_disconnect(error: PDBusError); cdecl; external LibDBus;
  36. function dbus_server_get_is_connected(error: PDBusError): dbus_bool_t; cdecl; external LibDBus;
  37. function dbus_server_get_address(error: PDBusError): PChar; cdecl; external LibDBus;
  38. procedure dbus_server_set_new_connection_function(server: PDBusServer;
  39. function_: DBusNewConnectionFunction; data: Pointer; free_data_function: DBusFreeFunction); cdecl; external LibDBus;
  40. function dbus_server_set_watch_functions(server: PDBusServer;
  41. add_function: DBusAddWatchFunction;
  42. remove_function: DBusRemoveWatchFunction;
  43. toggled_function: DBusWatchToggledFunction;
  44. data: Pointer;
  45. free_data_function: DBusFreeFunction): dbus_bool_t; cdecl; external LibDBus;
  46. function dbus_server_set_timeout_functions(server: PDBusServer;
  47. add_function: DBusAddTimeoutFunction;
  48. remove_function: DBusRemoveTimeoutFunction;
  49. toggled_function: DBusTimeoutToggledFunction;
  50. data: Pointer;
  51. free_data_function: DBusFreeFunction): dbus_bool_t; cdecl; external LibDBus;
  52. function dbus_server_set_auth_mechanisms(server: PDBusServer; const mechanisms: PPChar): dbus_bool_t; cdecl; external LibDBus;
  53. function dbus_server_allocate_data_slot(slot_p: Pdbus_int32_t): dbus_bool_t; cdecl; external LibDBus;
  54. procedure dbus_server_free_data_slot(slot_p: Pdbus_int32_t); cdecl; external LibDBus;
  55. function dbus_server_set_data(server: PDBusServer;
  56. slot: cint; data: Pointer; free_data_func: DBusFreeFunction): dbus_bool_t; cdecl; external LibDBus;
  57. function dbus_server_get_data(server: PDBusServer; slot: cint): Pointer; cdecl; external LibDBus;