Differences From Artifact [572eeb8e96]:
- File
src/OFStreamObserver.h
— part of check-in
[b554732eae]
at
2010-09-19 02:52:19
on branch trunk
— Improve OFStreamObserver.
It also looks at the cache of each stream now and does not block if
there is still data in the cache. (user: js, size: 3104) [annotate] [blame] [check-ins using]
To Artifact [ef35b95705]:
- File src/OFStreamObserver.h — part of check-in [b5da54000d] at 2010-10-24 12:54:28 on branch trunk — Add -[streamDidReceiveException:] to OFStreamObserverDelegate. (user: js, size: 3317) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 | /** * This callback is called when a stream did get ready for writing. * * \param stream The stream which did become ready for writing */ - (void)streamDidBecomeReadyForWriting: (OFStream*)stream; @end /** * \brief A class that can observe multiple streams at once. */ @interface OFStreamObserver: OFObject { OFMutableArray *readStreams; OFMutableArray *writeStreams; id <OFStreamObserverDelegate> delegate; #ifdef OF_HAVE_POLL OFDataArray *fds; OFMutableDictionary *fdToStream; #else fd_set readfds; fd_set writefds; int nfds; #endif } #ifdef OF_HAVE_PROPERTIES @property (retain) id <OFStreamObserverDelegate> delegate; #endif | > > > > > > > > | 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | /** * This callback is called when a stream did get ready for writing. * * \param stream The stream which did become ready for writing */ - (void)streamDidBecomeReadyForWriting: (OFStream*)stream; /** * This callback is called when an exception occurred on the stream. * * \param stream The stream on which an exception occurred */ - (void)streamDidReceiveException: (OFStream*)stream; @end /** * \brief A class that can observe multiple streams at once. */ @interface OFStreamObserver: OFObject { OFMutableArray *readStreams; OFMutableArray *writeStreams; id <OFStreamObserverDelegate> delegate; #ifdef OF_HAVE_POLL OFDataArray *fds; OFMutableDictionary *fdToStream; #else fd_set readfds; fd_set writefds; fd_set exceptfds; int nfds; #endif } #ifdef OF_HAVE_PROPERTIES @property (retain) id <OFStreamObserverDelegate> delegate; #endif |
︙ | ︙ |