Do you need help on a specific subject? Use the contact form (Request a blog entry) on the right hand side.

2015-10-07

Source Code Shop: Streaming File Reader

Today we added a streaming file reader to the source code shop. If you would like to shorten your development time you can now buy the StreamingFileReader source code for just $2. At that link you will see the public interface as well as an example on how to use the StreamingFileReader.

Use it either as an example on how to use NSStreamDelegate, NSInputStream and the "scheduleInRunLoop" and "removeFromRunLoop" calls, or use it to subclass your own streaming file reader.

In either case, implementing a streaming file reader that processes the file chunks that come due while there are no user events pending will improve the smoothness of the user experience.

Note: If you are looking for some simple guidance on NSStream, check out this post: Code sample: Multi staged file reading with NSStream from Swift

Happy coding...

Did this help?, then please help out a small independent.
If you decide that you want to make a small donation, you can do so by clicking this
link: a cup of coffee ($2) or use the popup on the right hand side for different amounts.
Payments will be processed by PayPal, receiver will be sales at balancingrock dot nl
Bitcoins will be gladly accepted at: 1GacSREBxPy1yskLMc9de2nofNv2SNdwqH

We don't get the world we wish for... we get the world we pay for.

No comments:

Post a Comment