ObjFW  Diff

Differences From Artifact [a227914da5]:

To Artifact [710f0fdfb9]:


66
67
68
69
70
71
72






























73
74
75
76
77
78
79
	OFString *_Nullable _SOCKS5Host;
	uint16_t _SOCKS5Port;
#ifdef OF_WII
	uint16_t _port;
#endif
}































/*!
 * The host to use as a SOCKS5 proxy.
 */
@property OF_NULLABLE_PROPERTY (copy, nonatomic) OFString *SOCKS5Host;

/*!
 * The port to use on the SOCKS5 proxy.







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
	OFString *_Nullable _SOCKS5Host;
	uint16_t _SOCKS5Port;
#ifdef OF_WII
	uint16_t _port;
#endif
}

/*!
 * Whether the socket is a listening socket.
 */
@property (readonly, nonatomic, getter=isListening) bool listening;

/*!
 * The remote address as a string
 *
 * @note This only works for accepted sockets!
 */
@property OF_NULLABLE_PROPERTY (readonly, nonatomic) OFString *remoteAddress;

#if !defined(OF_WII) && !defined(OF_NINTENDO_3DS)
/*!
 * Whether keep alives are enabled for the connection.
 *
 * @warning This is not available on the Wii or Nintendo 3DS!
 */
@property (nonatomic, getter=isKeepAliveEnabled) bool keepAliveEnabled;
#endif

#ifndef OF_WII
/*!
 * Whether TCP_NODELAY is enabled for the connection
 *
 * @warning This is not available on the Wii!
 */
@property (nonatomic, getter=isTCPNoDelayEnabled) bool TCPNoDelayEnabled;
#endif

/*!
 * The host to use as a SOCKS5 proxy.
 */
@property OF_NULLABLE_PROPERTY (copy, nonatomic) OFString *SOCKS5Host;

/*!
 * The port to use on the SOCKS5 proxy.
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
 *
 * @param block The block to execute when a new connection has been accepted.
 *		Returns whether the next incoming connection should be accepted
 *		by the specified block as well.
 */
- (void)asyncAcceptWithBlock: (of_tcp_socket_async_accept_block_t)block;
#endif

/*!
 * @brief Returns the remote address of the socket.
 *
 * Only works with accepted sockets!
 *
 * @return The remote address as a string
 */
- (nullable OFString *)remoteAddress;

/*!
 * @brief Returns whether the socket is a listening socket.
 *
 * @return Whether the socket is a listening socket
 */
- (bool)isListening;

#if !defined(OF_WII) && !defined(OF_NINTENDO_3DS)
/*!
 * @brief Enable or disable keep alive for the connection.
 *
 * @warning This is not available on the Wii or Nintendo 3DS!
 *
 * @param enabled Whether to enable or disable keep alives for the connection
 */
- (void)setKeepAliveEnabled: (bool)enabled;

/*!
 * @brief Returns whether keep alive is enabled for the connection.
 *
 * @warning This is not available on the Wii or Nintendo 3DS!
 *
 * @return Whether keep alives are enabled for the connection
 */
- (bool)isKeepAliveEnabled;
#endif

#ifndef OF_WII
/*!
 * @brief Enable or disable TCP_NODELAY for the connection.
 *
 * @warning This is not available on the Wii!
 *
 * @param enabled Whether to enable or disable TCP_NODELAY for the connection
 */
- (void)setTCPNoDelayEnabled: (bool)enabled;

/*!
 * @brief Returns whether TCP_NODELAY is enabled for the connection.
 *
 * @warning This is not available on the Wii!
 *
 * @return Whether TCP_NODELAY is enabled for the connection
 */
- (bool)isTCPNoDelayEnabled;
#endif
@end

#ifdef __cplusplus
extern "C" {
#endif
extern Class _Nullable of_tls_socket_class;
#ifdef __cplusplus
}
#endif

OF_ASSUME_NONNULL_END







<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<











233
234
235
236
237
238
239
























































240
241
242
243
244
245
246
247
248
249
250
 *
 * @param block The block to execute when a new connection has been accepted.
 *		Returns whether the next incoming connection should be accepted
 *		by the specified block as well.
 */
- (void)asyncAcceptWithBlock: (of_tcp_socket_async_accept_block_t)block;
#endif
























































@end

#ifdef __cplusplus
extern "C" {
#endif
extern Class _Nullable of_tls_socket_class;
#ifdef __cplusplus
}
#endif

OF_ASSUME_NONNULL_END