| Libbeagle Reference Manual | ||||
|---|---|---|---|---|
BeagleClient;
BeagleClient* beagle_client_new (const char *client_name);
BeagleClient* beagle_client_new_from_socket_path (const char *socket_path);
BeagleResponse* beagle_client_send_request (BeagleClient *client,
BeagleRequest *request,
GError **err);
gboolean beagle_client_send_request_async (BeagleClient *client,
BeagleRequest *request,
GError **err);
BeagleClient* beagle_client_new (const char *client_name);
Creates a new BeagleClient. If client_name is NULL it will default to "socket".
client_name : |
a string |
| Returns : | a newly created BeagleClient, or NULL if the client cannot be created. |
BeagleClient* beagle_client_new_from_socket_path (const char *socket_path);
Creates a new BeagleClient, connecting to the path with socket_path. NULL
is not allowed.
socket_path : |
a string of the path to the daemon socket |
| Returns : | a newly created BeagleClient, or NULL if the client cannot be created. |
BeagleResponse* beagle_client_send_request (BeagleClient *client, BeagleRequest *request, GError **err);
Synchronously send a BeagleRequest using the given BeagleClient.
client : |
a BeagleClient |
request : |
a BeagleRequest |
err : |
a location to return an error GError of type GIOChannelError. |
| Returns : | a BeagleResponse. |
gboolean beagle_client_send_request_async (BeagleClient *client, BeagleRequest *request, GError **err);
Asynchronously send a BeagleRequest using the given BeagleClient.
client : |
a BeagleClient |
request : |
a BeagleRequest |
err : |
a location to store a GError of type GIOChannelError |
| Returns : | TRUE on success and otherwise FALSE.
|