The NSOutputStream class is a subclass of NSStream that provides write-only stream functionality.
Questions tagged [nsoutputstream]
101 questions
1
vote
1 answer
Cocoa NSOutputStream send to a connection
I am new to Cocoa, but managed to get a connection (to a FTP) up and running, and I've set up an eventhandler for the NSInputStream iStream to alert every response (which also works).
What I manage to get is simply the hello message and a connection…

Chuck
- 13
- 1
- 4
1
vote
0 answers
iOS Simulator outputstream sends differently than iPhone's outputstream
My iOS app requires socket communication. I'm following this Ray Wenderlich tutorial for setting up the input and output streams. The server I'm using is Twisted. My app requires sending and receiving fast bursts of data generated by external events…

raj
- 187
- 1
- 11
1
vote
0 answers
iOS input stream receives fast data only if output stream is simultaneously sending
My iOS app requires socket communication. I'm following this Ray Wenderlich tutorial for setting up the input and output streams. The server I'm using is Twisted. My app requires sending and receiving fast bursts of data generated by external events…

raj
- 187
- 1
- 11
1
vote
1 answer
Sending JPEG NSData over TCP to Python server
I have a Python tcp server that has a iOS client. It is able to send data and receive, the only issue I am having is likely with encoding. I am trying to send a JPEG through TCP to the Python server and write the data to a JPEG on the server. The…

Michael Amici
- 308
- 1
- 4
- 18
1
vote
1 answer
Data is added from server
I am working on an app that is using NSOutputStream and NSInputStream to try it out and see what I can make happen. I have modified This tutorial to allow me to use a old computer as a server! What I am having an issue with is i am trying to send…

Charlie
- 222
- 3
- 20
1
vote
1 answer
Writing To NSStream Relying on hasSpaceAvailable method or Delegate Event NSStreamEventHasSpaceAvailable
While writing onto NSStream Should i Rely on
'hasSpaceAvailable' method or the event in the 'handle:event' method
'NSStreamEventHasSpaceAvailable'
Or Should i check 'hasSpaceAvailable' if not available, i have to retry after a particular
amount of…

raghul
- 1,008
- 1
- 15
- 33
1
vote
0 answers
NSOutput Stream Write operation failing via polling and run loop scheduling in background mode iOS 6
I have an app which uses the external accesssory framework. I have followed the example provided by Apple by the name EADemo. I am writing to the output stream via the polling mechanism and it works fine ntil iOS 5. When I am testing with iOS 6 and…

user2666050
- 11
- 2
1
vote
1 answer
NSInputStream can't read from TCP Connection [TCP-Server]
I created a TCP server using this (quite old) example by Apple. My server is up and running, listening on the specified Port for incoming connections.
Everything looks perfect, my client app can connect to the server and -stream:handleEvent: is…

Julian F. Weinert
- 7,474
- 7
- 59
- 107
1
vote
2 answers
How to share NSOutputStream from appdelegate?
I set socket connection in appdelegate from app starting up connecting to server.
in appdelegate.h
@interface AppDelegate : NSObject {
UIWindow *window;
UITabBarController *tabBarController;
…

STANLEY
- 171
- 1
- 1
- 8
1
vote
0 answers
iOS downloading large file using AFNetworking stops
I'm downloading a large video file using AFNetworking and it seems to stop at around 170MB without calling a timeout or throwing any other kind of error.
I have subclassed AFURLConnectionOperation to stream the data and am using an NSOutputStream…

Alex Brown
- 1,613
- 1
- 13
- 23
1
vote
3 answers
Transfer Multiple Images via NSInputStream/NSOutputStream
I have two NSInputStream and NSOutputStream connected to each other via network. I want to transfer core data objects and associated images from one device to other device. I have successfully converted the core data objects into JSON and…

Abbas Awan
- 113
- 1
- 14
1
vote
1 answer
NSInputStream and NSOutputStream problems
I have two NSInputStream and NSOutputStream between devices that are connected to each other via network. When I write something in output stream, the data is written until the NSStreamEventEndEncountered event occurs. I close the output stream but…

Abbas Awan
- 113
- 1
- 14
1
vote
1 answer
NSOutputStream not writing data properly
Using the NSStreamEventHasSpace available event, I am trying to write a simple NSString to to an NSOutputStream. Here is the contents of that event:
uint8_t *readBytes = (uint8_t *)[data mutableBytes];
readBytes += byteIndex; // instance variable to…

Greg
- 1,225
- 3
- 16
- 35
1
vote
3 answers
How to create a subclass of NSOutputStream
I am trying to write a subclass of NSOutputStream to perform a very simple function - keep track of the total number of bytes sent to the stream. However, I am running into an unexpected problem initializing an instance of the function. Here is…

Colin
- 2,089
- 25
- 34
1
vote
0 answers
Unable to write data into NSOutputStream
I am trying to send large sized images from the server to client using the write method of the NSOuptutStream. However I find that after writing 684032 bytes, no more bytes are getting written by the stream. I find this particularly strange. I am…

vivek
- 41
- 1
- 6