Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Cocoa] Subclassing NSMutableURLRequest



Hello List,

I have searched the archives, but did not really find an answer to my question, even though the title was the same...

I want to subclass NSMutableURLRequest, in order to create my own, specialized URLRequest (namely, XML-RPC). I thought that was a smart idea.

As NSURLRequest is deep-copied for transmission, I could overwrite copyWithZone: , and create my custom body there on 10.4

On 10.5 however, copyWithZone: (or copyMutableWithZone:, for that matter), is never called.

Using class_dump to take a peak at the class, I overwrote - (struct _CFURLRequest *)_CFURLRequest, and all is well.

Now... is that a good idea? Or should I not subclass NSMutableURLRequest at all?

Any hints or opinions are appreciated!

Alex


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.