Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
17 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
`HSCountingInputStream` is a simple example of an `NSInputStream` subclass | ||
that works around the bugs you'll run into if you try to pass such a subclass | ||
to NSURLRequest or CFHTTPMessageRef. See [my blog](http://bjhomer.blogspot.com/2011/04/subclassing-nsinputstream.html) | ||
for more information on the gory details of how it works. | ||
|
||
Note: | ||
|
||
This sample uses a few language features only available if you're | ||
using Xcode 4 and the LLVM Compiler 2.0, such as instance variables defined | ||
in the @implementation block. It also relies on the modern runtime to | ||
synthesize the instance variables. | ||
I used these features because they're cool and I wanted people to be aware | ||
of them. | ||
|
||
So if it won't compile for you, that's probably why. It shouldn't | ||
be hard to make the necessary changes to make it work for x86 or GCC 4.2, | ||
if that's what you need to do. |