/usr/share/GNUstep/Documentation/Developer/Base/Reference/NSStream.gsdoc is in gnustep-base-doc 1.25.1-2ubuntu3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 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 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 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 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 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 | <?xml version="1.0"?>
<!DOCTYPE gsdoc PUBLIC "-//GNUstep//DTD gsdoc 1.0.4//EN" "http://www.gnustep.org/gsdoc-1_0_4.dtd">
<gsdoc base="NSStream" up="Base">
<head>
<title>NSStream documentation</title>
<author name="Derek Zhou">
<email address="derekzhou@gmail.com">
derekzhou@gmail.com
</email>
</author>
<copy>2006 Free Software Foundation, Inc.</copy>
</head>
<body>
<front><contents /></front>
<chapter>
<heading>
Software documentation for the NSInputStream class
</heading>
<class name="NSInputStream" super="NSStream" ovadd="10.4.0" gvadd="1.2.0">
<declared>Foundation/NSStream.h</declared>
<desc>
NSInputStream is a subclass of NSStream that
provides read-only stream functionality.
</desc>
<method type="id" factory="yes" ovadd="10.4.0" gvadd="1.2.0">
<sel>inputStreamWithData:</sel>
<arg type="NSData*">data</arg>
<desc>
Creates and returns an initialized NSInputStream
object for reading from <var>data</var>.
</desc>
</method>
<method type="id" factory="yes" ovadd="10.4.0" gvadd="1.2.0">
<sel>inputStreamWithFileAtPath:</sel>
<arg type="NSString*">path</arg>
<desc>
Creates and returns an initialized NSInputStream
object that reads data from the file at the
specified <var>path</var>.
</desc>
</method>
<method type="id" factory="yes" ovadd="10.4.0" gvadd="1.2.0">
<sel>inputStreamWithURL:</sel>
<arg type="NSURL*">url</arg>
<desc>
Creates and returns an initialized NSInputStream
object that reads data from the specified URL.
</desc>
</method>
<method type="BOOL" ovadd="10.4.0" gvadd="1.2.0">
<sel>getBuffer:</sel>
<arg type="uint8_t**">buffer</arg>
<sel>length:</sel>
<arg type="NSUInteger*">len</arg>
<desc>
Returns a pointer to the read <var>buffer</var> in
<var>buffer</var> and, by reference, the number of
bytes available in <var>len</var>.
</desc>
</method>
<method type="BOOL" ovadd="10.4.0" gvadd="1.2.0">
<sel>hasBytesAvailable</sel>
<desc>
Returns <code>YES</code> if the receiver has bytes
available to read. The receiver may also return
<code>YES</code> if a read must be attempted in
order to determine the availability of bytes.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>initWithData:</sel>
<arg type="NSData*">data</arg>
<desc>
Returns an initialized NSInputStream object for
reading from <var>data</var>.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>initWithFileAtPath:</sel>
<arg type="NSString*">path</arg>
<desc>
Returns an initialized NSInputStream object for
reading from the file at the specified
<var>path</var>.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>initWithURL:</sel>
<arg type="NSURL*">url</arg>
<desc>
Returns an initialized NSInputStream object for
reading from the specified URL.
</desc>
</method>
<method type="NSInteger" ovadd="10.4.0" gvadd="1.2.0">
<sel>read:</sel>
<arg type="uint8_t*">buffer</arg>
<sel>maxLength:</sel>
<arg type="NSUInteger">len</arg>
<desc>
Reads up to <var>len</var> bytes into
<var>buffer</var>, returning the actual number of
bytes read.
</desc>
</method>
</class>
</chapter>
<chapter>
<heading>
Software documentation for the NSOutputStream class
</heading>
<class name="NSOutputStream" super="NSStream" ovadd="10.4.0" gvadd="1.2.0">
<declared>Foundation/NSStream.h</declared>
<desc>
NSOutputStream is a subclass of NSStream that
provides write-only stream functionality.
</desc>
<method type="id" factory="yes" ovadd="10.4.0" gvadd="1.2.0">
<sel>outputStreamToBuffer:</sel>
<arg type="uint8_t*">buffer</arg>
<sel>capacity:</sel>
<arg type="NSUInteger">capacity</arg>
<desc>
Creates and returns an initialized NSOutputStream
object that can write to <var>buffer</var>, up to a
maximum of <var>capacity</var> bytes.
</desc>
</method>
<method type="id" factory="yes" ovadd="10.4.0" gvadd="1.2.0">
<sel>outputStreamToFileAtPath:</sel>
<arg type="NSString*">path</arg>
<sel>append:</sel>
<arg type="BOOL">shouldAppend</arg>
<desc>
Creates and returns an initialized NSOutputStream
object for writing to the file specified by
<var>path</var>.
</desc>
</method>
<method type="id" factory="yes" ovadd="10.4.0" gvadd="1.2.0">
<sel>outputStreamToMemory</sel>
<desc>
Creates and returns an initialized NSOutputStream
object that will write stream data to memory.
</desc>
</method>
<method type="BOOL" ovadd="10.4.0" gvadd="1.2.0">
<sel>hasSpaceAvailable</sel>
<desc>
Returns <code>YES</code> if the receiver can be
written to, or if a write must be attempted in
order to determine if space is available.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>initToBuffer:</sel>
<arg type="uint8_t*">buffer</arg>
<sel>capacity:</sel>
<arg type="NSUInteger">capacity</arg>
<desc>
Returns an initialized NSOutputStream object that
can write to <var>buffer</var>, up to a maximum of
<var>capacity</var> bytes.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>initToFileAtPath:</sel>
<arg type="NSString*">path</arg>
<sel>append:</sel>
<arg type="BOOL">shouldAppend</arg>
<desc>
Returns an initialized NSOutputStream object for
writing to the file specified by <var>path</var>.
<br /> If <var>shouldAppend</var> is
<code>YES</code>, newly written data will be
appended to any existing file contents.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>initToMemory</sel>
<desc>
Returns an initialized NSOutputStream object that
will write to memory.
</desc>
</method>
<method type="NSInteger" ovadd="10.4.0" gvadd="1.2.0">
<sel>write:</sel>
<arg type="const uint8_t*">buffer</arg>
<sel>maxLength:</sel>
<arg type="NSUInteger">len</arg>
<desc>
Writes the contents of <var>buffer</var>, up to a
maximum of <var>len</var> bytes, to the receiver.
</desc>
</method>
</class>
</chapter>
<chapter>
<heading>
Software documentation for the NSStream class
</heading>
<class name="NSStream" super="NSObject" ovadd="10.4.0" gvadd="1.2.0">
<declared>Foundation/NSStream.h</declared>
<desc>
NSStream is an abstract class for objects
representing streams.
</desc>
<method type="void" factory="yes" ovadd="10.4.0" gvadd="1.2.0">
<sel>getStreamsToHost:</sel>
<arg type="NSHost*">host</arg>
<sel>port:</sel>
<arg type="NSInteger">port</arg>
<sel>inputStream:</sel>
<arg type="NSInputStream**">inputStream</arg>
<sel>outputStream:</sel>
<arg type="NSOutputStream**">outputStream</arg>
<desc>
Creates and returns by reference an NSInputStream
object and NSOutputStream object for a socket
connection with the specified <var>port</var> on
<var>host</var>.
</desc>
</method>
<method type="void" ovadd="10.4.0" gvadd="1.2.0">
<sel>close</sel>
<desc>
Closes the receiver. <br /> Repeated calls to this
method on the same stream are quietly ignored.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>delegate</sel>
<desc>
Returns the receiver's delegate.
</desc>
</method>
<method type="void" ovadd="10.4.0" gvadd="1.2.0">
<sel>open</sel>
<desc>
Opens the receiving stream. <br /> Upon completion of
the open operation, an NSStreamEventOpenCompleted event
is sent to the recevier's delegate. <br /> Repeated
calls to this method on the same stream are quietly
ignored.
</desc>
</method>
<method type="id" ovadd="10.4.0" gvadd="1.2.0">
<sel>propertyForKey:</sel>
<arg type="NSString*">key</arg>
<desc>
Returns the receiver's property for the specified
<var>key</var>.
</desc>
</method>
<method type="void" ovadd="10.4.0" gvadd="1.2.0">
<sel>removeFromRunLoop:</sel>
<arg type="NSRunLoop*">aRunLoop</arg>
<sel>forMode:</sel>
<arg type="NSString*">mode</arg>
<desc>
Removes the receiver from the NSRunLoop specified
by <var>aRunLoop</var> running in the <var>mode</var>.
<br /> Attempts to remove the receiver from a run
loop or a <var>mode</var> in which it has not been
scheduled are quietly ignored.
</desc>
</method>
<method type="void" ovadd="10.4.0" gvadd="1.2.0">
<sel>scheduleInRunLoop:</sel>
<arg type="NSRunLoop*">aRunLoop</arg>
<sel>forMode:</sel>
<arg type="NSString*">mode</arg>
<desc>
Schedules the receiver on <var>aRunLoop</var>
using the specified <var>mode</var>. <br /> You must
not attempt to add a stream to more than one run loop,
but you may call this method multiple times to add the
receiver in different modes for the same run loop.
</desc>
</method>
<method type="void" ovadd="10.4.0" gvadd="1.2.0">
<sel>setDelegate:</sel>
<arg type="id">delegate</arg>
<desc>
Sets the receiver's <var>delegate</var>.
</desc>
</method>
<method type="BOOL" ovadd="10.4.0" gvadd="1.2.0">
<sel>setProperty:</sel>
<arg type="id">property</arg>
<sel>forKey:</sel>
<arg type="NSString*">key</arg>
<desc>
Sets the value of the <var>property</var> specified by
<var>key</var> to <var>property</var>, returns
<code>YES</code> if the key-value pair are accepted
by the receiver.
</desc>
</method>
<method type="NSError*" ovadd="10.4.0" gvadd="1.2.0">
<sel>streamError</sel>
<desc>
Returns an NSError object representing the stream
error, or <code>nil</code> if no error has been
encountered.
</desc>
</method>
<method type="NSStreamStatus" ovadd="10.4.0" gvadd="1.2.0">
<sel>streamStatus</sel>
<desc>
Returns the receiver's status.
</desc>
</method>
</class>
</chapter>
<chapter>
<heading>
Software documentation for the
NSObject(NSStreamDelegate) informal
protocol
</heading>
<category name="NSStreamDelegate" class="NSObject" ovadd="10.4.0" gvadd="1.2.0">
<declared>Foundation/NSStream.h</declared>
<desc>
Informal protocol for delegates of instance of the
<ref type="class" id="NSStream">NSStream</ref>
class.
</desc>
<method type="void" ovadd="10.4.0" gvadd="1.2.0">
<sel>stream:</sel>
<arg type="NSStream*">sStream</arg>
<sel>handleEvent:</sel>
<arg type="NSStreamEvent">anEvent</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
</method>
</category>
</chapter>
<chapter>
<heading>
Software documentation for the NSStreamDelegate
protocol
</heading>
<protocol name="NSStreamDelegate" ovadd="10.7.0" gvadd="1.2.0">
<declared>Foundation/NSStream.h</declared>
<conform>NSObject</conform>
<desc>
<em>Description forthcoming.</em>
</desc>
<method type="void" ovadd="10.7.0" gvadd="1.2.0">
<sel>stream:</sel>
<arg type="NSStream*">sStream</arg>
<sel>handleEvent:</sel>
<arg type="NSStreamEvent">anEvent</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
</method>
</protocol>
</chapter>
</body>
</gsdoc>
|