Skip to content

Instantly share code, notes, and snippets.

@Adam0101
Created May 19, 2011 15:59
Show Gist options
  • Save Adam0101/981105 to your computer and use it in GitHub Desktop.
Save Adam0101/981105 to your computer and use it in GitHub Desktop.
asynch receiver
// Gather up all the asynch data as it comes in and store it in the blob
- (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data {
// Check to see if this is a new search, if so it will be nil, so create an object
if(tweetBlob == nil) {
tweetBlob = [[NSMutableData alloc]init];
[tweetBlob appendData:data];
}
else {
[tweetBlob appendData:data];
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment