Re: NSXMLParser initWIthData - Encoding?
Re: NSXMLParser initWIthData - Encoding?
- Subject: Re: NSXMLParser initWIthData - Encoding?
- From: David Duncan <email@hidden>
- Date: Fri, 21 May 2010 10:29:40 -0700
On May 21, 2010, at 10:23 AM, Patrick Rutkowski wrote:
> Any API that accepts binary data needs to give at least a hint as to what format the binary data should be. Saying that just it accepts "data" is disgusting. Period, end of argument.
The problem is that XML specifies the text encoding inside of the XML itself. Technically it is not possible to know the true encoding of an XML file until you have started parsing the file, hence you cannot actually specify the correct encoding before that point.
The API is doing what is appropriate for the technology. An "encoding" variant would at best be a hint as to how to start parsing before you get the actual encoding and switch encodings, and at worst would be a complete lie as to what encoding to use.
> If you want to advocate that it's perfectly fine to omit information about the format of binary data, then you're just a moron. I'm not saying that you're a moron for accidentally forgetting to document it, but if you want to say (as you seem to be doing) that it's OK to consciously leave it out, then you're just a moron.
Insulting people is not a good way to get help on a public mailing list.
--
David Duncan
Apple DTS Animation and Printing
_______________________________________________
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:
This email sent to email@hidden