1 // This file is under GNU General Public License 3.0
13 typedef enum _PEP_transports {
14 // auto transport chooses transport per message automatically
17 // PEP_trans_whatsapp,
22 typedef struct _PEP_transport_t PEP_transport_t;
24 typedef PEP_STATUS (*sendto_t)(PEP_SESSION session, const message *msg);
25 typedef PEP_STATUS (*readnext_t)(PEP_SESSION session, message **msg,
26 PEP_transport_t **via);
28 struct _PEP_transport_t {
29 uint8_t id; // transport ID
30 sendto_t sendto; // sendto function
31 readnext_t readnext; // readnext function
32 bool long_message_supported; // flag if this transport supports
34 bool formatted_message_supported; // flag if this transport supports
36 PEP_text_format native_text_format; // native format of the transport
39 extern PEP_transport_t transports[PEP_trans__count];
41 typedef uint64_t transports_mask;