What the difference in using async NSURLConnection from a static method with an object as delegate, and calling it IN an object with self as delegate?
When i try to send – initWithRequest:delegate:startImmed开发者_开发技巧iately: message to NSURLConnection from a class method, passing an ad-hoc delegate object, delegate methods never gets called. When, instead, – initWithRequest:delegate:startImmediately: is sent by an object, and the delegate of NSURLConnection is self, than all goes OK. Someone can explain me why? i stucked here for three days or so ^^'
There's no difference. If your delegate methods aren't getting called it is because your implementation is obviously incorrect. The target delegate must be in the same runloop, and if you're releasing autoreleased objects or something like that, your implementation is wrong.
Post your code or recheck your work.
精彩评论