• BlackBerry Dynamics
  • Runtime library for iOS applications
  • 10.2.0.83
GD_C_sys_socket.h
Go to the documentation of this file.
1 /*
2  * (c) 2016 Good Technology Corporation. All rights reserved.
3  */
4 
5 #pragma once
6 
7 #include <sys/types.h>
8 #include <sys/socket.h>
9 #include <sys/select.h>
10 
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18 
19 #ifndef GD_C_API
20 # if !defined(_WIN32)
21 # define GD_C_API __attribute__((visibility("default")))
22 # else
23 # define GD_C_API
24 # endif
25 #endif
26 
29  GD_C_API int GD_accept(int, struct sockaddr * __restrict addr, socklen_t * __restrict addrlen);
30 
33  GD_C_API int GD_bind(int, const struct sockaddr *, socklen_t);
34 
37  GD_C_API int GD_connect(int, const struct sockaddr *, socklen_t);
38 
41  GD_C_API int GD_getpeername(int, struct sockaddr * __restrict, socklen_t * __restrict);
42 
45  GD_C_API int GD_getsockname(int, struct sockaddr * __restrict, socklen_t * __restrict);
46 
49  GD_C_API int GD_getsockopt(int, int, int, void * __restrict, socklen_t * __restrict);
50 
53  GD_C_API int GD_listen(int, int);
54 
57  GD_C_API ssize_t GD_recv(int, void *, size_t, int);
58 
61  GD_C_API ssize_t GD_recvfrom(int, void *, size_t, int, struct sockaddr * __restrict, socklen_t * __restrict);
62 
65  GD_C_API ssize_t GD_recvmsg(int, struct msghdr *, int);
66 
69  GD_C_API ssize_t GD_send(int, const void *, size_t, int);
70 
73  GD_C_API ssize_t GD_sendmsg(int, const struct msghdr *, int);
74 
77  GD_C_API ssize_t GD_sendto(int, const void *, size_t, int, const struct sockaddr *, socklen_t);
78 
81  GD_C_API int GD_setsockopt(int, int, int, const void *, socklen_t);
82 
85  GD_C_API int GD_shutdown(int, int);
86 
89  GD_C_API int GD_sockatmark(int);
90 
93  GD_C_API int GD_socket(int, int, int);
94 
97  GD_C_API int GD_socketpair(int, int, int, int *);
98 
101  GD_C_API int GD_ioctlsocket(int, long, unsigned long*);
102 
105  GD_C_API int GD_gethostname(char* name, size_t len);
106 
109  GD_C_API int GD_select(int, fd_set*, fd_set*, fd_set*, struct timeval*);
110 
111 #ifdef __cplusplus
112 }
113 #endif
114 
GD_bind
int GD_bind(int, const struct sockaddr *, socklen_t)
C API.
GD_connect
int GD_connect(int, const struct sockaddr *, socklen_t)
C API.
GD_setsockopt
int GD_setsockopt(int, int, int, const void *, socklen_t)
C API.
GD_recvmsg
ssize_t GD_recvmsg(int, struct msghdr *, int)
C API.
GD_listen
int GD_listen(int, int)
C API.
GD_getsockopt
int GD_getsockopt(int, int, int, void *__restrict, socklen_t *__restrict)
C API.
GD_recv
ssize_t GD_recv(int, void *, size_t, int)
C API.
GD_sendto
ssize_t GD_sendto(int, const void *, size_t, int, const struct sockaddr *, socklen_t)
C API.
GD_socket
int GD_socket(int, int, int)
C API.
GD_sockatmark
int GD_sockatmark(int)
C API.
GD_select
int GD_select(int, fd_set *, fd_set *, fd_set *, struct timeval *)
GD_sendmsg
ssize_t GD_sendmsg(int, const struct msghdr *, int)
C API.
GD_socketpair
int GD_socketpair(int, int, int, int *)
C API.
GD_recvfrom
ssize_t GD_recvfrom(int, void *, size_t, int, struct sockaddr *__restrict, socklen_t *__restrict)
C API.
GD_gethostname
int GD_gethostname(char *name, size_t len)
C API.
GD_shutdown
int GD_shutdown(int, int)
C API.
GD_getpeername
int GD_getpeername(int, struct sockaddr *__restrict, socklen_t *__restrict)
C API.
GD_send
ssize_t GD_send(int, const void *, size_t, int)
C API.
GD_getsockname
int GD_getsockname(int, struct sockaddr *__restrict, socklen_t *__restrict)
C API.
GD_accept
int GD_accept(int, struct sockaddr *__restrict addr, socklen_t *__restrict addrlen)
C API.
GD_ioctlsocket
int GD_ioctlsocket(int, long, unsigned long *)
C API.