Differences From Artifact [077e4589a5]:
- File src/OFTCPSocket.h — part of check-in [2b6a12065e] at 2018-12-08 16:53:30 on branch trunk — Separate error methods for async method delegates (user: js, size: 9863) [annotate] [blame] [check-ins using]
To Artifact [e932bc199a]:
- File
src/OFTCPSocket.h
— part of check-in
[064dbe5127]
at
2018-12-11 22:57:46
on branch trunk
— Include an exception in delegate methods
Otherwise, there would be two methods for every operation: One for
success and one for failure. It also makes it easy to forget about
handling failure, so it's better to always pass an optional exception. (user: js, size: 9360) [annotate] [blame] [check-ins using]
︙ | |||
60 61 62 63 64 65 66 67 68 69 | 60 61 62 63 64 65 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 | + + + + - + + + + - - + + - - - - - - - - - - - - - - - - - - - - - - - | */ @protocol OFTCPSocketDelegate <OFStreamDelegate> @optional /*! * @brief A method which is called when a socket connected. * * @param socket The socket which connected * @param host The host connected to * @param port The port on the host connected to * @param exception An exception that occurred while connecting, or nil on * success */ - (void)socket: (OF_KINDOF(OFTCPSocket *))socket didConnectToHost: (OFString *)host |
︙ |