CPURLConnection starting
Reported by Angus Hardie | September 4th, 2008 @ 05:27 PM | in 0.5.1
The documentation currently states that CPURLConnection +(CPURLConnection)connectionWithRequest:(CPURLRequest)aRequest delegate:(id)aDelegate
returns a "a connection that can be started to initiate the request"
but actually the connection seems to be started by this method automatically, no need to call start.
(Actually calling start seems to cause problems in Camino)
Comments and changes to this ticket
-
Karl Adam September 7th, 2008 @ 08:39 PM
I'm confused, do you mean you'll add docs that say it starts from -connectionWithRequest:delegate: or -start ?
I'd like to suggest that it require the -start call to kick off the connection, besides it being the behavior of NSURLConnection, it also maintains the behavior better that you've created an object, can configure your objects appropriately for the expected data then start the url connection.
-
Ross Boucher September 8th, 2008 @ 08:41 PM
- State changed from new to open
Karl, when you create a connection like this:
var connection = [[CPURLConnection alloc] initWithRequest:aRequest delegate:aDelegate startImmediately:NO]
It will not fire immediately, so you can modify it as you please. These init methods were accidentally left out of the documentation. We'll add them back in with the next update.
The class method +connectionWithRequest does fire immediately. Personally, I prefer this behavior. Is having the init enough?
-
Karl Adam September 8th, 2008 @ 09:08 PM
yes, this is fine since it matches what the NSURLConnection APIs do which is how I became confused by this bug. thanks for the heads up.
-
Ross Boucher September 10th, 2008 @ 06:31 PM
- State changed from open to resolved
The docs have been updated in the inline codebase, and will be updated on the site sometime tonight.
-
Francisco Tolmasky September 13th, 2008 @ 01:13 PM
- Milestone set to 0.5.1
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
The Cappuccino Web Framework, including AppKit, Foundation, and Objective-J.