1 # Generated by h2py from /boot/develop/headers/be/net/netinet/in.h
3 # Included from socket.h
5 # Included from BeBuild.h
6 B_BEOS_VERSION_4
= 0x0400
7 B_BEOS_VERSION_4_5
= 0x0450
8 B_BEOS_VERSION_5
= 0x0500
9 B_BEOS_VERSION
= B_BEOS_VERSION_5
10 B_BEOS_VERSION_MAUI
= B_BEOS_VERSION_5
19 def _UNUSED(x
): return x
22 # Included from sys/types.h
24 # Included from time.h
26 # Included from be_setup.h
27 def __std(ref
): return ref
35 # Included from null.h
39 # Included from size_t.h
41 # Included from stddef.h
43 # Included from wchar_t.h
45 CLK_TCK
= CLOCKS_PER_SEC
48 # Included from sys/time.h
50 # Included from ByteOrder.h
52 # Included from endian.h
53 __LITTLE_ENDIAN
= 1234
54 LITTLE_ENDIAN
= __LITTLE_ENDIAN
55 __BYTE_ORDER
= __LITTLE_ENDIAN
56 BYTE_ORDER
= __BYTE_ORDER
60 BIG_ENDIAN
= __BIG_ENDIAN
61 __BYTE_ORDER
= __BIG_ENDIAN
62 BYTE_ORDER
= __BYTE_ORDER
66 PDP_ENDIAN
= __PDP_ENDIAN
68 # Included from SupportDefs.h
70 # Included from Errors.h
72 # Included from limits.h
74 # Included from float.h
80 FLT_MIN_10_EXP
= (-37)
86 DBL_MIN_10_EXP
= (-308)
89 LDBL_MANT_DIG
= DBL_MANT_DIG
91 LDBL_MIN_EXP
= DBL_MIN_EXP
92 LDBL_MIN_10_EXP
= DBL_MIN_10_EXP
93 LDBL_MAX_EXP
= DBL_MAX_EXP
94 LDBL_MAX_10_EXP
= DBL_MAX_10_EXP
101 SHRT_MIN
= (-32767-1)
103 LONG_MIN
= (-2147483647L-1)
104 LONG_MAX
= (2147483647L)
113 LOGIN_NAME_MAX
= (32)
121 SSIZE_MAX
= (2147483647L)
125 _POSIX_ARG_MAX
= (32768)
126 _POSIX_CHILD_MAX
= (1024)
127 _POSIX_LINK_MAX
= (1)
128 _POSIX_LOGIN_NAME_MAX
= (9)
129 _POSIX_MAX_CANON
= (255)
130 _POSIX_MAX_INPUT
= (255)
131 _POSIX_NAME_MAX
= (255)
132 _POSIX_NGROUPS_MAX
= (0)
133 _POSIX_OPEN_MAX
= (128)
134 _POSIX_PATH_MAX
= (1024)
135 _POSIX_PIPE_BUF
= (512)
136 _POSIX_SSIZE_MAX
= (2147483647L)
137 _POSIX_STREAM_MAX
= (8)
138 _POSIX_TTY_NAME_MAX
= (256)
139 _POSIX_TZNAME_MAX
= (3)
140 B_GENERAL_ERROR_BASE
= LONG_MIN
141 B_OS_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x1000
142 B_APP_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x2000
143 B_INTERFACE_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x3000
144 B_MEDIA_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x4000
145 B_TRANSLATION_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x4800
146 B_MIDI_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x5000
147 B_STORAGE_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x6000
148 B_POSIX_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x7000
149 B_MAIL_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x8000
150 B_PRINT_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0x9000
151 B_DEVICE_ERROR_BASE
= B_GENERAL_ERROR_BASE
+ 0xa000
152 B_ERRORS_END
= (B_GENERAL_ERROR_BASE
+ 0xffff)
153 E2BIG
= (B_POSIX_ERROR_BASE
+ 1)
154 ECHILD
= (B_POSIX_ERROR_BASE
+ 2)
155 EDEADLK
= (B_POSIX_ERROR_BASE
+ 3)
156 EFBIG
= (B_POSIX_ERROR_BASE
+ 4)
157 EMLINK
= (B_POSIX_ERROR_BASE
+ 5)
158 ENFILE
= (B_POSIX_ERROR_BASE
+ 6)
159 ENODEV
= (B_POSIX_ERROR_BASE
+ 7)
160 ENOLCK
= (B_POSIX_ERROR_BASE
+ 8)
161 ENOSYS
= (B_POSIX_ERROR_BASE
+ 9)
162 ENOTTY
= (B_POSIX_ERROR_BASE
+ 10)
163 ENXIO
= (B_POSIX_ERROR_BASE
+ 11)
164 ESPIPE
= (B_POSIX_ERROR_BASE
+ 12)
165 ESRCH
= (B_POSIX_ERROR_BASE
+ 13)
166 EFPOS
= (B_POSIX_ERROR_BASE
+ 14)
167 ESIGPARM
= (B_POSIX_ERROR_BASE
+ 15)
168 EDOM
= (B_POSIX_ERROR_BASE
+ 16)
169 ERANGE
= (B_POSIX_ERROR_BASE
+ 17)
170 EPROTOTYPE
= (B_POSIX_ERROR_BASE
+ 18)
171 EPROTONOSUPPORT
= (B_POSIX_ERROR_BASE
+ 19)
172 EPFNOSUPPORT
= (B_POSIX_ERROR_BASE
+ 20)
173 EAFNOSUPPORT
= (B_POSIX_ERROR_BASE
+ 21)
174 EADDRINUSE
= (B_POSIX_ERROR_BASE
+ 22)
175 EADDRNOTAVAIL
= (B_POSIX_ERROR_BASE
+ 23)
176 ENETDOWN
= (B_POSIX_ERROR_BASE
+ 24)
177 ENETUNREACH
= (B_POSIX_ERROR_BASE
+ 25)
178 ENETRESET
= (B_POSIX_ERROR_BASE
+ 26)
179 ECONNABORTED
= (B_POSIX_ERROR_BASE
+ 27)
180 ECONNRESET
= (B_POSIX_ERROR_BASE
+ 28)
181 EISCONN
= (B_POSIX_ERROR_BASE
+ 29)
182 ENOTCONN
= (B_POSIX_ERROR_BASE
+ 30)
183 ESHUTDOWN
= (B_POSIX_ERROR_BASE
+ 31)
184 ECONNREFUSED
= (B_POSIX_ERROR_BASE
+ 32)
185 EHOSTUNREACH
= (B_POSIX_ERROR_BASE
+ 33)
186 ENOPROTOOPT
= (B_POSIX_ERROR_BASE
+ 34)
187 ENOBUFS
= (B_POSIX_ERROR_BASE
+ 35)
188 EINPROGRESS
= (B_POSIX_ERROR_BASE
+ 36)
189 EALREADY
= (B_POSIX_ERROR_BASE
+ 37)
190 EILSEQ
= (B_POSIX_ERROR_BASE
+ 38)
191 ENOMSG
= (B_POSIX_ERROR_BASE
+ 39)
192 ESTALE
= (B_POSIX_ERROR_BASE
+ 40)
193 EOVERFLOW
= (B_POSIX_ERROR_BASE
+ 41)
194 EMSGSIZE
= (B_POSIX_ERROR_BASE
+ 42)
195 EOPNOTSUPP
= (B_POSIX_ERROR_BASE
+ 43)
196 ENOTSOCK
= (B_POSIX_ERROR_BASE
+ 44)
203 # Included from TypeConstants.h
204 B_HOST_IS_LENDIAN
= 1
205 B_HOST_IS_BENDIAN
= 0
206 def B_HOST_TO_LENDIAN_DOUBLE(arg
): return (double
)(arg
)
208 def B_HOST_TO_LENDIAN_FLOAT(arg
): return (float)(arg
)
210 def B_HOST_TO_LENDIAN_INT64(arg
): return (uint64
)(arg
)
212 def B_HOST_TO_LENDIAN_INT32(arg
): return (uint32
)(arg
)
214 def B_HOST_TO_LENDIAN_INT16(arg
): return (uint16
)(arg
)
216 def B_HOST_TO_BENDIAN_DOUBLE(arg
): return __swap_double(arg
)
218 def B_HOST_TO_BENDIAN_FLOAT(arg
): return __swap_float(arg
)
220 def B_HOST_TO_BENDIAN_INT64(arg
): return __swap_int64(arg
)
222 def B_HOST_TO_BENDIAN_INT32(arg
): return __swap_int32(arg
)
224 def B_HOST_TO_BENDIAN_INT16(arg
): return __swap_int16(arg
)
226 def B_LENDIAN_TO_HOST_DOUBLE(arg
): return (double
)(arg
)
228 def B_LENDIAN_TO_HOST_FLOAT(arg
): return (float)(arg
)
230 def B_LENDIAN_TO_HOST_INT64(arg
): return (uint64
)(arg
)
232 def B_LENDIAN_TO_HOST_INT32(arg
): return (uint32
)(arg
)
234 def B_LENDIAN_TO_HOST_INT16(arg
): return (uint16
)(arg
)
236 def B_BENDIAN_TO_HOST_DOUBLE(arg
): return __swap_double(arg
)
238 def B_BENDIAN_TO_HOST_FLOAT(arg
): return __swap_float(arg
)
240 def B_BENDIAN_TO_HOST_INT64(arg
): return __swap_int64(arg
)
242 def B_BENDIAN_TO_HOST_INT32(arg
): return __swap_int32(arg
)
244 def B_BENDIAN_TO_HOST_INT16(arg
): return __swap_int16(arg
)
246 B_HOST_IS_LENDIAN
= 0
247 B_HOST_IS_BENDIAN
= 1
248 def B_HOST_TO_LENDIAN_DOUBLE(arg
): return __swap_double(arg
)
250 def B_HOST_TO_LENDIAN_FLOAT(arg
): return __swap_float(arg
)
252 def B_HOST_TO_LENDIAN_INT64(arg
): return __swap_int64(arg
)
254 def B_HOST_TO_LENDIAN_INT32(arg
): return __swap_int32(arg
)
256 def B_HOST_TO_LENDIAN_INT16(arg
): return __swap_int16(arg
)
258 def B_HOST_TO_BENDIAN_DOUBLE(arg
): return (double
)(arg
)
260 def B_HOST_TO_BENDIAN_FLOAT(arg
): return (float)(arg
)
262 def B_HOST_TO_BENDIAN_INT64(arg
): return (uint64
)(arg
)
264 def B_HOST_TO_BENDIAN_INT32(arg
): return (uint32
)(arg
)
266 def B_HOST_TO_BENDIAN_INT16(arg
): return (uint16
)(arg
)
268 def B_LENDIAN_TO_HOST_DOUBLE(arg
): return __swap_double(arg
)
270 def B_LENDIAN_TO_HOST_FLOAT(arg
): return __swap_float(arg
)
272 def B_LENDIAN_TO_HOST_INT64(arg
): return __swap_int64(arg
)
274 def B_LENDIAN_TO_HOST_INT32(arg
): return __swap_int32(arg
)
276 def B_LENDIAN_TO_HOST_INT16(arg
): return __swap_int16(arg
)
278 def B_BENDIAN_TO_HOST_DOUBLE(arg
): return (double
)(arg
)
280 def B_BENDIAN_TO_HOST_FLOAT(arg
): return (float)(arg
)
282 def B_BENDIAN_TO_HOST_INT64(arg
): return (uint64
)(arg
)
284 def B_BENDIAN_TO_HOST_INT32(arg
): return (uint32
)(arg
)
286 def B_BENDIAN_TO_HOST_INT16(arg
): return (uint16
)(arg
)
288 def B_SWAP_DOUBLE(arg
): return __swap_double(arg
)
290 def B_SWAP_FLOAT(arg
): return __swap_float(arg
)
292 def B_SWAP_INT64(arg
): return __swap_int64(arg
)
294 def B_SWAP_INT32(arg
): return __swap_int32(arg
)
296 def B_SWAP_INT16(arg
): return __swap_int16(arg
)
298 def htonl(x
): return B_HOST_TO_BENDIAN_INT32(x
)
300 def ntohl(x
): return B_BENDIAN_TO_HOST_INT32(x
)
302 def htons(x
): return B_HOST_TO_BENDIAN_INT16(x
)
304 def ntohs(x
): return B_BENDIAN_TO_HOST_INT16(x
)
307 INADDR_ANY
= 0x00000000
308 INADDR_BROADCAST
= 0xffffffff
309 INADDR_LOOPBACK
= 0x7f000001
321 B_UDP_MAX_SIZE
= (65536 - 1024)
323 FDSETSIZE
= FD_SETSIZE
325 def _FDMSKNO(fd
): return ((fd
) / NFDBITS
)
327 def _FDBITNO(fd
): return ((fd
) % NFDBITS
)