On Jun 9, 2013, at 5:54 AM, Jean-Daniel Dupas wrote:
> The NSConnectionDelegate protocol has a method that pass you the response:
>
> - (void)connection:(NSURLConnection *)connection
> didReceiveResponse:(NSURLResponse *)response
>
> You can test if the response is of type NSHTTPURLResponse (
On 9 Jun 2013, at 16:54, Jean-Daniel Dupas wrote:
>
> Le 9 juin 2013 à 11:35, Gerriet M. Denkmann a écrit :
>
>> This works fine, but blocks my for 1 sec on a good day - who know how long
>> if the net is slow:
>>
>> url = something/which/might/exist/or/not.gif
>> data = [ NSData dataWithCo
Le 9 juin 2013 à 11:35, Gerriet M. Denkmann a écrit :
> This works fine, but blocks my for 1 sec on a good day - who know how long if
> the net is slow:
>
> url = something/which/might/exist/or/not.gif
> data = [ NSData dataWithContentsOfURL: url options: mask error: &outError ];
>
> So I am
On Jun 9, 2013, at 5:35 AM, Gerriet M. Denkmann wrote:
> Is there a way to get just the status (in this case 404) without parsing the
> data?
> I looked at the NSURLConnection delegate methods, but did not find anything
> which looked appropriate.
I do something like this:
- (void) connecti
Laurent:
We are definitely seeing more issues with NSURLConnection on iOS 6. In
particular, it seems that iOS 6 re-establishes data connectivity a little bit
slower than before, especially from a locked state. Because our team had not
implemented data connectivity (Reachability) tests exactly c
I seem to have gotten an uptick of HTTP Too many Redirects. I don't know if its
yet iOS 6 or just so many people upgrading that the servers are wonky (Google
API servers we use mostly).
On Oct 3, 2012, at 6:23 PM, Laurent Daudelin wrote:
> Anybody extensively using NSURLConnection seeing more
Hi Koen,
Your approach doesn't sound that wrong to me.
How about having a master controller that is more or less what you have now,
and split the functionality that handles the data stream out into a separate
class that the master controller calls on to fetch the data? Then according to
what i
On Sep 19, 2012, at 12:14 PM, Koen van der Drift
wrote:
> Thanks for the link, lots of info there. Unfortunately he doesn't
> discuss the responsibility of the MVC classes in the slides regarding
> the best location for the NSURLConnection code. I got that and the
> paring already working, but
Thanks for the link, lots of info there. Unfortunately he doesn't
discuss the responsibility of the MVC classes in the slides regarding
the best location for the NSURLConnection code. I got that and the
paring already working, but need to make it more flexible.
- Koen.
On Wed, Sep 19, 2012 at 2:0
I haven't implemented what you're describing, but you might want to look
at Marcus Zarra's talk on Flexible JSON Importing. I don't know what
you're parsing (JSON, XML, or something else). I found the slides for
Marcus' Flexible JSON Importing talk here:
http://www.mactech.com/conference/presentati
On Sep 9, 2011, at 9:10 AM, Andreas Grosam wrote:
> One other thing is, using Instruments makes the scenario worse. When
> Instruments is connected, the app crashes much sooner due to memory problems.
> So, I support my observations on logs, too.
That sounds suspicious. You may have memory err
On Sep 9, 2011, at 6:54 AM, Don Quixote de la Mancha wrote:
> I don't know how to fix NSURLConnection, but an alternative would be
> to use the source to some other HTTP client. By having the source
> code, you would have full control over the buffering.
>
> For example, libcurl is available un
On Sep 9, 2011, at 4:06 AM, Andreas Grosam wrote:
> I'm trying to use a NSURLConnection to download a large data file (>10 MB)
> from a web service to the iPhone. Currently, testing on iOS 4.2.1, on a
> device. The connection is established over WIFI.
>
> The problem I get with NSURLConnection
On Sep 9, 2011, at 6:10 PM, Andreas Grosam wrote:
>
> I already did this:
I meant:
- (NSCachedURLResponse *)connection:(NSURLConnection *)connection
willCacheResponse:(NSCachedURLResponse *)cachedResponse {
return nil;
}
the infamous Copy and Paste error :)
_
On Sep 9, 2011, at 4:15 PM, glenn andreas wrote:
>
> On Sep 9, 2011, at 6:06 AM, Andreas Grosam wrote:
>
>> Dir Members,
>>
>> I'm trying to use a NSURLConnection to download a large data file (>10 MB)
>> from a web service to the iPhone. Currently, testing on iOS 4.2.1, on a
>> device. The
On Sep 9, 2011, at 3:59 PM, David Duncan wrote:
> On Sep 9, 2011, at 4:06 AM, Andreas Grosam wrote:
>
>> The problem I get with NSURLConnection is, that it internally uses a lot
>> (really a lot) memory for its data buffers. It seems, the connection reads
>> as much data as it can from the net
On Sep 9, 2011, at 6:06 AM, Andreas Grosam wrote:
> Dir Members,
>
> I'm trying to use a NSURLConnection to download a large data file (>10 MB)
> from a web service to the iPhone. Currently, testing on iOS 4.2.1, on a
> device. The connection is established over WIFI.
>
> The problem I get wi
On Sep 9, 2011, at 4:06 AM, Andreas Grosam wrote:
> The problem I get with NSURLConnection is, that it internally uses a lot
> (really a lot) memory for its data buffers. It seems, the connection reads as
> much data as it can from the network and a tries to safe it in internal
> buffers, no ma
On Fri, Sep 9, 2011 at 4:06 AM, Andreas Grosam wrote:
> I'm trying to use a NSURLConnection to download a large data file (>10 MB)
> from a web service to the iPhone. Currently, testing on iOS 4.2.1, on a
> device. The connection is established over WIFI.
>
> The problem I get with NSURLConnecti
On Sep 8, 2011, at 2:46 AM, Mike Abdullah wrote:
>> In delegate connectionDidFinishLoading handling as follows:
>> -(void)connectionDidFinishLoading:(NSURLConnection *)connection
>> {
>> @try {
>>CFRunLoopStop(m_runLoopRef);
>>[m_connection release];
>>m_c
On 7 Sep 2011, at 14:37, Payal Mundhada wrote:
> Hi Mike,
>
> I am creating request as follows:
>
> @implementation WebService
> -(void)makeRequest
> {
> m_URLRequest= [NSMutableURLRequest requestWithURL:url];
> [m_URLRequest setHTTPMethod:@"POST"];
>
On Sep 8, 2011, at 7:12 AM, Mike Abdullah wrote:
>> since we are downloading large data from server so NSURLConnection delegate
>> mentioned below is getting called continuously and meanwhile also need to
>> update UI, so calling the web service function itself in a saperate thread.
>
> A Mac
On 8 Sep 2011, at 14:30, Payal Mundhada wrote:
> Hi,
> I am calling this function in a thread using NSThread method from Main
> thread (Handling UI)
>
> [NSThread detachNewThreadSelector:@selector(startDownload) toTarget:self
> withObject:nil];
>
> -(void)startDownload
> {[myWebService mak
Show us some code.
On 2 Sep 2011, at 14:27, Payal Mundhada wrote:
>
> Hi All,
>
> I am making a web service call with NSURLConnection.
>
> Response is received correctly on Mac OS X 10.5 and Mac OS X 10.6.
>
> On Mac OS X 10.7, I am getting response as "Bad Request" for the same
> request.
Thanks to all on the learning curve
On Jun 26, 11:12 pm, Tito Ciuro wrote:
> Hello,
>
> If you have access to the Developer Forums, check the very first entry in
> Core OS named "Five Reasons Why Synchronous Networking Is Bad", by Apple's
> Quinn "The Eskimo!":
>
> https://devforums.apple.c
Hello,
If you have access to the Developer Forums, check the very first entry in Core
OS named "Five Reasons Why Synchronous Networking Is Bad", by Apple's Quinn
"The Eskimo!":
https://devforums.apple.com/thread/9606?tstart=0
Cheers,
-- Tito
On Jun 26, 2011, at 9:51 PM, Jerry Krinock wrote:
On 2011 Jun 26, at 09:52, Fritz Anderson wrote:
> Synchronous network operations are almost always a bad idea. …, …, …, …,
and the error object that you get from
-sendSynchronousRequest:returningResponse:error: if it fails is quite
nondescript.
___
The asynchronous option allows you to report progress and utilize your data
immediately and do with it whatever you wish while the synchronous option
requires you wait until the entire data has been retrieved, possibly an issue
if you have data of any size. Also, for UI responsiveness, the synch
On 26 Jun 2011, at 11:37 AM, R wrote:
> Any opinions on which approach is better.
>
> NSData *data = [NSURLConnection sendSynchronousRequest:request
> returningResponse:&response
> error:&error];
>
> OR
>
> connectionInProgress=[[N
On 2010 Sep 23, at 02:21, Devraj Mukherjee wrote:
> Previous version I used NSURLConnection to make synchronous calls to
> the API, parsing the data and then returning results. Only problem of
> course is that my API client had to be used in threads so the UI
> didn't get locked up while the requ
On Sep 23, 2010, at 4:21 AM, Devraj Mukherjee wrote:
> Previous version I used NSURLConnection to make synchronous calls to
> the API
> I would like to move towards using async requests. I can grab / parse
> the data using the delegate methods, what I am struggling with is how
> I return the data
On Mon, Aug 2, 2010 at 1:20 PM, Fritz Anderson wrote:
> On 2 Aug 2010, at 11:50 AM, David Duncan wrote:
>
>> On Aug 2, 2010, at 9:40 AM, Fritz Anderson wrote:
>>
>>> The didReceiveData: callback asserts that the data accumulator exists. In
>>> certain circumstances (it seems to be with four of th
On 2 Aug 2010, at 11:50 AM, David Duncan wrote:
> On Aug 2, 2010, at 9:40 AM, Fritz Anderson wrote:
>
>> The didReceiveData: callback asserts that the data accumulator exists. In
>> certain circumstances (it seems to be with four of these requests started
>> nearly simultaneously), the assertio
On Aug 2, 2010, at 9:40 AM, Fritz Anderson wrote:
> The didReceiveData: callback asserts that the data accumulator exists. In
> certain circumstances (it seems to be with four of these requests started
> nearly simultaneously), the assertion is triggered. self.dataAccumulator is
> nil, and ther
On 2010 Jul 13, at 18:25, Laurent Daudelin wrote:
> That's very useful and gives me at least a starting point
One more thing I should have mentioned. After you get this thing working and
have these passwords, tokens, or whatever, if you want to store them
persistently, do it the Correct Way™
On Jul 13, 2010, at 12:40 PM, Laurent Daudelin wrote:
> I guess everybody was sleeping yesterday when I sent this so, I'll resend :-)
>
> I'm using an NSURLConnection to extract information from a website. The
> website used to have a simple authentication process based on cookies. Now,
> they
On Jul 13, 2010, at 17:36, Jerry Krinock wrote:
>
> On 2010 Jul 13, at 09:40, Laurent Daudelin wrote:
>
>> I guess everybody was sleeping yesterday when I sent this so, I'll resend :-)
>
> Well, although that was true in my case, it's also likely that no one knows.
>
>> I've been trying to cre
On 2010 Jul 13, at 09:40, Laurent Daudelin wrote:
> I guess everybody was sleeping yesterday when I sent this so, I'll resend :-)
Well, although that was true in my case, it's also likely that no one knows.
> I've been trying to create a NSURLCredential with the user ID and password
> but that
On May 29, 2010, at 10:12 PM, Jens Alfke wrote:
>
> On May 29, 2010, at 11:53 AM, Nava Carmon wrote:
>
>> When I initialize the NSURLConnection I define a timeout in my
>> NSURLMutableRequest in order not to stuck the GUI and let the user to work
>> with application. On timeout I get didFailW
On May 29, 2010, at 11:53 AM, Nava Carmon wrote:
> When I initialize the NSURLConnection I define a timeout in my
> NSURLMutableRequest in order not to stuck the GUI and let the user to work
> with application. On timeout I get didFailWithError in
> NSURLConnectionDelegate and show a message t
Thanks for answering.
Indeed I found a pattern and probably the explanation, now I need to found the
appropriate solution:
What happen is that My iphone application presents the data that comes as an
xml files, which I fetch from a various urls on the same server. There are
problematic urls, t
On 2010 May 28, at 02:58, Nava Carmon wrote:
> When I enter same link in Safari it takes a second to bring data.
I understand that you're saying it "works OK at the same time from the same IP
address from Safari", meaning that you have ruled out being throttled by this
"certain server", or you
On May 28, 2010, at 2:58 AM, Nava Carmon wrote:
> sometimes it's just stuck after initialing and don't get into connection's
> delegate methods. I'm working with WiFi & 3G and the same server all the
> time. When it comes to didFailWithError i see that mostly it was a timeout
> error.
Do you
Instruments adds some extra safeguarding to some of their tools, so you
should whittle down your functionality until you know this-or-that code will
cause or not cause the crash, depending on inclusion. It's possible what
you're seeing is a side-effect that is set up elsewhere and dies in a
differ
On Mar 5, 2010, at 7:54 PM, Stuart Malin wrote:
> I expected the sendSynchronousRequest approach to return an NSHTTPURLResponse
> object without an error because, according to the docs, the synchronous
> method is built on top of the asynchronous methods.
Yes, but its semantics are different;
On 2010 Mar 05, at 19:54, Stuart Malin wrote:
> I haven't been able to find any documentation or relevant Web results
> regarding a situation I'm experiencing:
Indeed, see below.
> I get different [error] results for the same identical NSURLRequest when I
> execute the request using NSURLConn
On 2010-01-09, at 22:31, Damien Cooke wrote:
> [appendedData appendData:[[[NSString
> stringWithFormat:@"ProdBuild=%@",[self productBuild]]
> stringByAddingPercentEscapesUsingEncoding:
> NSASCIIStringEncoding]dataUsingEncoding:NSASCIIStringEncoding
> allowLossyConversion:YES]];
As an as
Thanks Jason,
I knew it would be simple. Thank you so much.
Regards
Damien
On 10/01/2010, at 2:35 PM, Jason Foreman wrote:
>
> On Jan 9, 2010, at 9:31 PM, Damien Cooke wrote:
>
>> here is my code to send this data
>>
>
>> [appendedData appendData:[[[NSString
>> stringWithFormat:@"Prod
On Jan 9, 2010, at 9:31 PM, Damien Cooke wrote:
> here is my code to send this data
>
> [appendedData appendData:[[[NSString
> stringWithFormat:@"ProdName=%@",[self applicationName]]
> stringByAddingPercentEscapesUsingEncoding: NSASCIIStringEncoding]
> dataUsingEncoding:NSASCIIStringEn
On Dec 9, 2009, at 3:11 AM, Dalmazio Brisinda wrote:
> Alright, well, we may have to reevaluate an alternate approach to this
> instead of via a QuickLook generator. It seems there are other issues over an
> above sandboxing which are more problematic.
>
> Does anyone know if a version of the
Alright, well, we may have to reevaluate an alternate approach to this instead
of via a QuickLook generator. It seems there are other issues over an above
sandboxing which are more problematic.
Does anyone know if a version of the QuickLook framework with debugging symbols
is available? I've al
This discussion would be better done in the quicklook-dev mailing list. And
in fact, it already took place there.
Please avoid cross posting questions like this.
On Tue, Dec 8, 2009 at 7:16 PM, Dalmazio Brisinda wrote:
> Thanks for that. Okay, I see the QuickLook docs sort of allude to this in
>
On Dec 8, 2009, at 10:16 AM, Dalmazio Brisinda wrote:
> Thanks for that. Okay, I see the QuickLook docs sort of allude to this in
> regards to using Web-Kit plugins within QuickLook generators. Which gets me
> thinking: would it then be possible to maybe connect to the server via local
> distri
On Tue, Dec 8, 2009 at 10:13 AM, Dalmazio Brisinda wrote:
> Well, it's the way the system is architected -- we are using QuickLook
> plugins for icon badging, and that badging depends on the state of certain
> elements of the filesystem which is maintained in a separate server process.
This see
Thanks for that. Okay, I see the QuickLook docs sort of allude to this in
regards to using Web-Kit plugins within QuickLook generators. Which gets me
thinking: would it then be possible to maybe connect to the server via local
distributed objects instead of using the NSURLConnection framework? I
Well, it's the way the system is architected -- we are using QuickLook plugins
for icon badging, and that badging depends on the state of certain elements of
the filesystem which is maintained in a separate server process.
Best,
Dalmazio
On 2009-12-08, at 5:09 AM, Mike Abdullah wrote:
> I'
hi-
On Dec 8, 2009, at 11:48 AM, David Duncan wrote:
> My understanding is Quicklook plugins are not allowed to make network
> connections due to sandbox restrictions.
We ran into this same problem when QL plugins were first included with the OS.
thanks!-
-lance
_
On Dec 8, 2009, at 2:13 AM, Dalmazio Brisinda wrote:
> I'm writing a QuickLook plugin that, as part of the preview process, makes an
> http call to a (localhost) server to obtain data that is then used to
> generate the preview image.
>
> The code below works fine outside the QuickLook architec
I'm pretty certain Apple disallows use of non-file URLs in Quick Look
generators for the simple reason that a generator should run as quickly as
possible. Generators should also be fairly standalone - why do you need to POST
to generate a preview/thumbnail?
On 8 Dec 2009, at 10:13, Dalmazio Bri
On 26 Nov 2009, at 07:23, Alexander Spohr wrote:
>
> Am 25.11.2009 um 23:25 schrieb Jerry Krinock:
>
>>
>> On 2009 Nov 25, at 12:53, Alexander Spohr wrote:
>>
>>> I meant NSURLConnection.
>>
>> * Normally the delegate is receiving and storing headers, data and errors
>> for you. You should
Am 25.11.2009 um 23:25 schrieb Jerry Krinock:
>
> On 2009 Nov 25, at 12:53, Alexander Spohr wrote:
>
>> I meant NSURLConnection.
>
> * Normally the delegate is receiving and storing headers, data and errors for
> you. You should retain the delegate as long as you are interested in the
> hea
On 2009 Nov 25, at 12:53, Alexander Spohr wrote:
> I meant NSURLConnection.
If it is indeed not documented whether or not NSURLConnection retains its
delegate, I believe you can design for either case.
* When a NSURLConnection completes, you may release it or allow it to be
autoreleased.
*
Shame on me!
I meant NSURLConnection.
Andy, sorry that I bothered you with the wrong test.
This is one example where copy-paste is better than fresh typing...
So the (corrected) question still stands:
is NSURLConnection retaining its delegate?
atze
Am 25.11.2009 um 21:19 schrieb Andy L
On Oct 15, 2009, at 3:59 PM, Jens Alfke wrote:
On Oct 15, 2009, at 11:44 AM, Stuart Malin wrote:
I have looked through the NSURLConnection class reference, the
NSURLRequest class reference, the URL Loading System guide, queried
Google, searched mailing list archives, and even looked throug
On Oct 15, 2009, at 11:44 AM, Stuart Malin wrote:
I have looked through the NSURLConnection class reference, the
NSURLRequest class reference, the URL Loading System guide, queried
Google, searched mailing list archives, and even looked through
NSURLConnection.h, but can not find documenta
Jens, thank you for your answer.
On Sep 27, 2009, at 7:59 PM, Jens Alfke wrote:
On Sep 27, 2009, at 2:25 AM, Sergey Shapovalov wrote:
This makes me think that chunked upload from stream via
NSURLConnection has been broken in iPhone OS 3.x. Unfortunately, in
real life I can't upload my file
On Sep 27, 2009, at 2:25 AM, Sergey Shapovalov wrote:
This makes me think that chunked upload from stream via
NSURLConnection has been broken in iPhone OS 3.x. Unfortunately, in
real life I can't upload my file by using setHTTPBody instead of
setHTTPBodyStream because it's too big to store
Hello again.
It looks like I've got more info on the issue. I've performed some
additional investigation and figured out that if you substitute the
lines
NSInputStream* stream = [NSInputStream inputStreamWithFileAtPath:
filePath];
[request setHTTPBodyStream: stream];
with
On Sep 21, 2009, at 5:08 AM, Michael C.Silva wrote:
Is there anyway to completely remove these headers from being
inserted by NSURLConnection?
They are not present in my NSMutableURLRequest, but show up in the
stream sent out by the NSURLConnection. I see no way to control this.
I don't k
Ben Lachman wrote:
The only problem is that I'm seeing lousy download speed,
particularly over wifi (~200K/sec over 3G, <100K/sec over wifi).
Any ideas as to why this might be or if there is anything I can do
to improve things?
Make sure the iPhone wifi isn't experiencing high interferenc
On 2 Aug 2009, at 06:50, Ben Lachman wrote:
I'm working on a small iPhone project this weekend that among other
things downloads some medium sized video files. To do this I set up
a NSURLConnection and use an NSOutputStream to write the data to my
apps' documents folder as it arrives. The
On 2009 Jul 30, at 17:44, Jack Carbaugh wrote:
I am working on a program that is basically a wrapper around some
web pages.
I am using NSURLConnection to download the various pages needed,
however, with 2 specific users, NSURLConnection returns immediately
with an error, NSURLErrorDomain
Thanks, Jeff, others are also saying that implementing this method
doesn't always fix the problem. Which makes sense: presumably Apple's
implementation amounts to "return request;", so it is hard to see how
that method could be at the root of the problem.
I hope everybody is filing bug report
I'm not sure that this is the full story. My app Vienna implements
connection:willSendRequest: redirectResponse: at AsyncConnection.m: 396
http://vienna-rss.svn.sourceforge.net/viewvc/vienna-rss/trunk/2.3.0/AsyncConnection.m?view=markup
However, I'm seeing crash reports from users on 10.5.7, f
Thanks, Andrew,
I believe that Colin Gray got to the bottom of this at Stack Overflow:
http://stackoverflow.com/questions/916718/nsurlconnection-crashing-under-10-5-7
Dennis
Andrew Farmer wrote:
On 27 May 2009, at 18:20, Dennis Hartigan-O'Connor wrote:
I have a very similar problem: my simpl
On 27 May 2009, at 18:20, Dennis Hartigan-O'Connor wrote:
I have a very similar problem: my simple program that downloads
stock prices has been working fine but intermittently crashes on
10.5.7, whether I use sendSynchronousRequest or
stringWithContentsOfURL. For me, too, everything is fine
I have a very similar problem: my simple program that downloads stock
prices has been working fine but intermittently crashes on 10.5.7,
whether I use sendSynchronousRequest or stringWithContentsOfURL. For
me, too, everything is fine for 10-15 minutes and then the program crashes.
Here is the
Thanks - that's good information.
On Mon, May 18, 2009 at 10:35 AM, Keary Suska wrote:
> On May 17, 2009, at 9:07 PM, Eric E. Dolecki wrote:
>
> I just want to be sure of something - if I set the images to cache, when I
>> load the same url again, the image is coming from memory - because I put
On May 17, 2009, at 9:07 PM, Eric E. Dolecki wrote:
I just want to be sure of something - if I set the images to cache,
when I
load the same url again, the image is coming from memory - because I
put in
a progress bar and the images loaded already I thought would have an
instantly populated
On Fri, May 15, 2009 at 12:56 PM, Luke the Hiesterman
wrote:
>
> On May 14, 2009, at 5:35 PM, Michael Ash wrote:
>
>> I agree completely that the simplest code should win, but I also think
>> that the thread adds complexity, not just overhead.
>
> My point is that some programmers might find using
On May 14, 2009, at 5:35 PM, Michael Ash wrote:
I agree completely that the simplest code should win, but I also think
that the thread adds complexity, not just overhead.
My point is that some programmers might find using NSThread fits their
way of thinking best. Others might find NSURLConn
I'm going to try NSURLConnection first I guess and see how it goes. I'm
loading larger images that get resized down in the table so I'll have the
larger images cached for display in a details view.
Thanks for all of this valuable feedback!
Eric
On Thu, May 14, 2009 at 11:21 PM, George Warner wrot
On Thu, 14 May 2009 16:52:48 -0400, Eric E. Dolecki"
wrote:
Just curious, but if I am loading images into a UIImageView in table
cells
from online URLs, is it better to use NSThread or use async
NSURLConnection
to ensure that the scrolling is smooth while images are loaded in?
This proba
On Thu, May 14, 2009 at 6:42 PM, Luke the Hiesterman wrote:
> To add to that thought, I should add that even if there is a performance
> difference, I'd be surprised if it's anything that anyone would notice. It's
> generally a mistake to assume there's a performance problem with a certain
> appro
I am not saying that the threads created by NSURLConnection are in any
way faster than those created manually. I am saying that
NSURLConnection is going to use its own thread internally whatever you
do, so throwing another thread into the mix is only adding additional
overhead.
As it happ
On 14 May 2009, at 23:39, Luke the Hiesterman wrote:
Why is it assumed that threads created by NSURLConnection are faster
than threads created manually with NSThread?
It isn't.
Mike's point is that the chances of someone who is asking whether or
not to use NSThread on a developer mailing l
To add to that thought, I should add that even if there is a
performance difference, I'd be surprised if it's anything that anyone
would notice. It's generally a mistake to assume there's a performance
problem with a certain approach until you've actually seen the
performance problem. In ca
Why is it assumed that threads created by NSURLConnection are faster
than threads created manually with NSThread?
Luke
On May 14, 2009, at 3:36 PM, Mike Abdullah wrote:
Threads would be unnecessary hassle and probably slower performing.
NSURLConnection maintains its own private thread for p
Threads would be unnecessary hassle and probably slower performing.
NSURLConnection maintains its own private thread for performing the
work of all open URL connections, even if you are using the
synchronous API. By using NSThread, you are just bringing an extra
unnecessary thread into the
I actually think for a simple case like this one, the NSThread
approach will have simpler, more straightforward code. I say go with
whichever way makes more sense for your style of coding.
Luke
On May 14, 2009, at 2:56 PM, Michael Ash wrote:
On Thu, May 14, 2009 at 4:52 PM, Eric E. Dolecki
On Thu, May 14, 2009 at 4:52 PM, Eric E. Dolecki wrote:
> Just curious, but if I am loading images into a UIImageView in table cells
> from online URLs, is it better to use NSThread or use async NSURLConnection
> to ensure that the scrolling is smooth while images are loaded in?
I'd recommend the
This was indeed a bug and has been fixed in Mac OS X 10.5.7
See http://www.openradar.me/6700222 for the bug report.
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin requests or moderator comments to the list.
Contact the
On Fri, May 1, 2009 at 12:00 PM, Nick Hristov wrote:
> One more comment on self->ivar... I used this approach because using [self
> connection] or self.connection (they are both the same thing) amount to an
> extra message call.
This is true, and sometimes you want to do this, while other times y
Am 01.05.2009 um 18:00 schrieb Nick Hristov:
One more comment on self->ivar... I used this approach because using
[self
connection] or self.connection (they are both the same thing) amount
to an
extra message call.
Then just use ivar, without self->
It amounts to the same (no call) but lo
Yes, those result in a message call, though it's a very fast message
call. Within your instance methods, however, you can just access the
ivar directly, e.g, "connection" without a message call and without
"self->connection".
-Jeff
On May 1, 2009, at 11:00 AM, Nick Hristov wrote:
Thank
Thank you all for your suggestions. I will use the runloop to wait on
response.
One more comment on self->ivar... I used this approach because using [self
connection] or self.connection (they are both the same thing) amount to an
extra message call.
Nick
On Thu, Apr 30, 2009 at 11:09 AM, Jeff Jo
On Apr 30, 2009, at 12:53 AM, Kyle Sluder wrote:
On Thu, Apr 30, 2009 at 1:44 AM, Jeff Johnson
wrote:
On an unrelated note, your use of "self->connection", etc., is non-
standard
and not advised. You should be using direct ivar access "connection",
properties "self.connection", or accessor me
On Wed, Apr 29, 2009 at 11:31 PM, Nick Hristov
wrote:
> - (id) initWithURL: (NSURL*) someurl
> {
>self = [super init];
>if (self != nil) {
>self->url = [someurl copy];
>NSURLRequest * request = [NSURLRequest requestWithURL:self->url
> cachePolicy: NSURLRequestUseProtocolCac
On 30 Apr 2009, at 05:31, Nick Hristov wrote:
Hello,
I am currently working on a small iphone app, and I am facing some
difficulty with getting NSURLConnection to ... connect. Basically my
unit
tests don't pass: connection is never made.
Here is a snippet of the non-working code:
- (id)
On Thu, Apr 30, 2009 at 1:44 AM, Jeff Johnson
wrote:
> On an unrelated note, your use of "self->connection", etc., is non-standard
> and not advised. You should be using direct ivar access "connection",
> properties "self.connection", or accessor methods "[self connection]".
Sure, `self->connecti
1 - 100 of 185 matches
Mail list logo