Type Method

outputStreamToMemory

Creates and returns an initialized output stream that will write stream data to memory.

Declaration

+ (instancetype)outputStreamToMemory;

Return Value

An initialized output stream that will write stream data to memory.

Discussion

The stream must be opened before it can be used.

You retrieve the contents of the memory stream by sending the message propertyForKey: to the receiver with an argument of NSStreamDataWrittenToMemoryStreamKey.

See Also

Creating Streams

+ outputStreamToBuffer:capacity:

Creates and returns an initialized output stream that can write to a provided buffer.

+ outputStreamToFileAtPath:append:

Creates and returns an initialized output stream for writing to a specified file.

+ outputStreamWithURL:append:

Creates and returns an initialized output stream for writing to a specified URL.

- initToMemory

Returns an initialized output stream that will write to memory.

- initToBuffer:capacity:

Returns an initialized output stream that can write to a provided buffer.

- initToFileAtPath:append:

Returns an initialized output stream for writing to a specified file.

- initWithURL:append:

Returns an initialized output stream for writing to a specified URL.