Differences From Artifact [fb3f587e28]:
- File
src/OFTCPSocket.m
— part of check-in
[fb590316ba]
at
2014-01-30 12:26:12
on branch trunk
— Rename +[UDPSocket hostForAddress:port:]
It is now called +[getHost:andPort:forAddress:]. This makes it much
clearer from the selector alone what it actually does. (user: js, size: 11138) [annotate] [blame] [check-ins using]
To Artifact [0b9ade0423]:
- File src/OFTCPSocket.m — part of check-in [7908c035e4] at 2014-01-30 12:26:19 on branch trunk — Rename of_tcpsocket* -> of_tcp_socket_* (user: js, size: 11143) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
70 71 72 73 74 75 76 | OFThread *_sourceThread; OFTCPSocket *_socket; OFString *_host; uint16_t _port; id _target; SEL _selector; # ifdef OF_HAVE_BLOCKS | | | | 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 | OFThread *_sourceThread; OFTCPSocket *_socket; OFString *_host; uint16_t _port; id _target; SEL _selector; # ifdef OF_HAVE_BLOCKS of_tcp_socket_async_connect_block_t _connectBlock; # endif OFException *_exception; } - initWithSourceThread: (OFThread*)sourceThread socket: (OFTCPSocket*)socket host: (OFString*)host port: (uint16_t)port target: (id)target selector: (SEL)selector; # ifdef OF_HAVE_BLOCKS - initWithSourceThread: (OFThread*)sourceThread socket: (OFTCPSocket*)socket host: (OFString*)host port: (uint16_t)port block: (of_tcp_socket_async_connect_block_t)block; # endif @end @implementation OFTCPSocket_ConnectThread - initWithSourceThread: (OFThread*)sourceThread socket: (OFTCPSocket*)socket host: (OFString*)host |
︙ | ︙ | |||
120 121 122 123 124 125 126 | } # ifdef OF_HAVE_BLOCKS - initWithSourceThread: (OFThread*)sourceThread socket: (OFTCPSocket*)socket host: (OFString*)host port: (uint16_t)port | | | 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 | } # ifdef OF_HAVE_BLOCKS - initWithSourceThread: (OFThread*)sourceThread socket: (OFTCPSocket*)socket host: (OFString*)host port: (uint16_t)port block: (of_tcp_socket_async_connect_block_t)block { self = [super init]; @try { _sourceThread = [sourceThread retain]; _socket = [socket retain]; _host = [host copy]; |
︙ | ︙ | |||
329 330 331 332 333 334 335 | objc_autoreleasePoolPop(pool); } # ifdef OF_HAVE_BLOCKS - (void)asyncConnectToHost: (OFString*)host port: (uint16_t)port | | | 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 | objc_autoreleasePoolPop(pool); } # ifdef OF_HAVE_BLOCKS - (void)asyncConnectToHost: (OFString*)host port: (uint16_t)port block: (of_tcp_socket_async_connect_block_t)block { void *pool = objc_autoreleasePoolPush(); [[[[OFTCPSocket_ConnectThread alloc] initWithSourceThread: [OFThread currentThread] socket: self host: host |
︙ | ︙ | |||
479 480 481 482 483 484 485 | { [OFRunLoop OF_addAsyncAcceptForTCPSocket: self target: target selector: selector]; } #ifdef OF_HAVE_BLOCKS | | | 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 | { [OFRunLoop OF_addAsyncAcceptForTCPSocket: self target: target selector: selector]; } #ifdef OF_HAVE_BLOCKS - (void)asyncAcceptWithBlock: (of_tcp_socket_async_accept_block_t)block { [OFRunLoop OF_addAsyncAcceptForTCPSocket: self block: block]; } #endif - (void)setKeepAlivesEnabled: (bool)enable |
︙ | ︙ |