]> git.saurik.com Git - wxWidgets.git/blame - src/unix/gsockunx.h
Couple more Unicode fixes.
[wxWidgets.git] / src / unix / gsockunx.h
CommitLineData
a324a7bc
GL
1#ifndef __GSOCK_UNX_H
2#define __GSOCK_UNX_H
3
4#include <wx/gsocket.h>
5
6/* Definition of GSocket */
7struct _GSocket {
8 int m_fd;
9 GAddress *m_local, *m_peer;
10 GSocketError m_error;
11
12 bool m_blocking, m_server, m_stream, m_oriented;
13
14 /* Fallbacks */
15 GSocketFallback m_fbacks[GSOCK_MAX_EVENT];
16 char *m_data[GSOCK_MAX_EVENT];
17
18 /* IO calls associated */
19 bool m_iocalls[GSOCK_MAX_EVENT];
20
21 char *m_gui_dependent;
22};
23
24/* Definition of GAddress */
25struct _GAddress {
26 struct sockaddr *m_addr;
27 size_t m_len;
28
29 GAddressType m_family;
30 int m_realfamily;
31
32 GSocketError m_error;
33};
34
35void _GSocket_Enable(GSocket *socket, GSocketEvent event);
36void _GSocket_Disable(GSocket *socket, GSocketEvent event);
37int _GSocket_Recv_Stream(GSocket *socket, char *buffer, int size);
38int _GSocket_Recv_Dgram(GSocket *socket, char *buffer, int size);
39int _GSocket_Send_Stream(GSocket *socket, const char *buffer, int size);
40int _GSocket_Send_Dgram(GSocket *socket, const char *buffer, int size);
41void _GSocket_Install_Fallback(GSocket *socket, GSocketEvent count);
42void _GSocket_Uninstall_Fallback(GSocket *socket, GSocketEvent count);
43void _GSocket_Detected_Read(GSocket *socket);
44void _GSocket_Detected_Write(GSocket *socket);
45void _GSocket_GUI_Init(GSocket *socket);
46void _GSocket_GUI_Destroy(GSocket *socket);
47void _GAddress_translate_from(GAddress *address,
48 struct sockaddr *addr, int len);
49void _GAddress_translate_to(GAddress *address,
50 struct sockaddr **addr, int *len);
51
52/* Internet address family */
53void _GAddress_Init_INET(GAddress *address);
54/* Local address family */
55void _GAddress_Init_UNIX(GAddress *address);
56
57#endif