91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
|
* @return The string to repeat the write with or nil if it should not repeat
*/
typedef OFString *_Nullable (^OFStreamAsyncWriteStringBlock)(
size_t bytesWritten, id _Nullable exception);
#endif
/**
* @protocol OFStreamDelegate OFStream.h ObjFW/OFStream.h
*
* A delegate for OFStream.
*/
@protocol OFStreamDelegate <OFObject>
@optional
/**
* @brief This method is called when data was read asynchronously from a
|
|
|
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
|
* @return The string to repeat the write with or nil if it should not repeat
*/
typedef OFString *_Nullable (^OFStreamAsyncWriteStringBlock)(
size_t bytesWritten, id _Nullable exception);
#endif
/**
* @protocol OFStreamDelegate OFStream.h ObjFW/ObjFW.h
*
* A delegate for OFStream.
*/
@protocol OFStreamDelegate <OFObject>
@optional
/**
* @brief This method is called when data was read asynchronously from a
|
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
|
didWriteString: (OFString *)string
encoding: (OFStringEncoding)encoding
bytesWritten: (size_t)bytesWritten
exception: (nullable id)exception;
@end
/**
* @class OFStream OFStream.h ObjFW/OFStream.h
*
* @brief A base class for different types of streams.
*
* @warning Even though the OFCopying protocol is implemented, it does *not*
* return an independent copy of the stream, but instead retains it.
* This is so that the stream can be used as a key for a dictionary,
* so context can be associated with a stream. Using a stream in more
|
|
|
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
|
didWriteString: (OFString *)string
encoding: (OFStringEncoding)encoding
bytesWritten: (size_t)bytesWritten
exception: (nullable id)exception;
@end
/**
* @class OFStream OFStream.h ObjFW/ObjFW.h
*
* @brief A base class for different types of streams.
*
* @warning Even though the OFCopying protocol is implemented, it does *not*
* return an independent copy of the stream, but instead retains it.
* This is so that the stream can be used as a key for a dictionary,
* so context can be associated with a stream. Using a stream in more
|