Translation update done using Pootle.
[gammu.git] / include / gammu-callback.h
blob2e2ff028068a2a562a8bcd560aa9d6fd753302d9
1 /**
2 * \file gammu-callback.h
3 * \author Michal Čihař
5 * Callback handlers.
6 */
7 #ifndef __gammu_callback_h
8 #define __gammu_callback_h
10 /**
11 * \defgroup Callback Callback
12 * Generic state machine callback layer.
15 #include <gammu-types.h>
16 #include <gammu-message.h>
17 #include <gammu-call.h>
19 /**
20 * Callback for incoming calls.
22 * \ingroup Callback
24 typedef void (*IncomingCallCallback) (GSM_StateMachine * s, GSM_Call *call,
25 void *user_data);
27 /**
28 * Callback for incoming SMS.
30 * \ingroup Callback
32 typedef void (*IncomingSMSCallback) (GSM_StateMachine * s, GSM_SMSMessage *sms,
33 void *user_data);
35 /**
36 * Callback for incoming cell broadcast.
38 * \ingroup Callback
40 typedef void (*IncomingCBCallback) (GSM_StateMachine * s, GSM_CBMessage *cb,
41 void *user_data);
43 /**
44 * Callback for icoming USSD.
46 * \ingroup Callback
48 typedef void (*IncomingUSSDCallback) (GSM_StateMachine * s,
49 GSM_USSDMessage *ussd, void *user_data);
51 /**
52 * Callback for sending SMS.
54 * \ingroup Callback
56 typedef void (*SendSMSStatusCallback) (GSM_StateMachine * s, int status,
57 int MessageReference, void *user_data);
59 /**
60 * Sets callback for incoming calls.
62 * \param s State machine.
63 * \param callback Pointer to callback function.
64 * \param user_data Second parameter which will be passed to callback.
66 * \ingroup Callback
68 void GSM_SetIncomingCallCallback(GSM_StateMachine * s,
69 IncomingCallCallback callback,
70 void *user_data);
72 /**
73 * Sets callback for incoming SMSes.
75 * \param s State machine.
76 * \param callback Pointer to callback function.
77 * \param user_data Second parameter which will be passed to callback.
79 * \ingroup Callback
81 void GSM_SetIncomingSMSCallback(GSM_StateMachine * s,
82 IncomingSMSCallback callback, void *user_data);
84 /**
85 * Sets callback for incoming CB.
87 * \param s State machine.
88 * \param callback Pointer to callback function.
89 * \param user_data Second parameter which will be passed to callback.
91 * \ingroup Callback
93 void GSM_SetIncomingCBCallback(GSM_StateMachine * s,
94 IncomingCBCallback callback, void *user_data);
96 /**
97 * Sets callback for incoming USSD.
99 * \param s State machine.
100 * \param callback Pointer to callback function.
101 * \param user_data Second parameter which will be passed to callback.
103 * \ingroup Callback
105 void GSM_SetIncomingUSSDCallback(GSM_StateMachine * s,
106 IncomingUSSDCallback callback,
107 void *user_data);
110 * Sets callback for sending SMS.
112 * \param s State machine.
113 * \param callback Pointer to callback function.
114 * \param user_data Second parameter which will be passed to callback.
116 * \ingroup Callback
118 void GSM_SetSendSMSStatusCallback(GSM_StateMachine * s,
119 SendSMSStatusCallback callback,
120 void *user_data);
121 #endif
123 /* Editor configuration
124 * vim: noexpandtab sw=8 ts=8 sts=8 tw=72: