CPURLConnection starting
Reported by Angus Hardie | 2008-09-04 17:27:07 UTC | 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 2008-09-07 20:39:06 UTC
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 2008-09-08 20:41:47 UTC
- 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 2008-09-08 21:08:17 UTC
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 2008-09-10 18:31:10 UTC
- 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 2008-09-13 13:13:47 UTC
- 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.