Skip to content

Handling of parsing errors with NSError** #1

Merged
1 commit merged into from Mar 1, 2011

2 participants

@0xced
0xced commented Mar 1, 2011

I added error handling with a NSError** parameter in the designated initializer. This way, you can't get a half constructed invalid XML document.

This also suppresses the NSLogs, it's now up to the caller to decide what to do with the error.

@0xced 0xced Handling of parsing errors with NSError**
-initWithData: becomes -initWithData:error: and returns nil when a parsing error occurs
-documentWithData: becomes -documentWithData:error:
22fe349
@nfarina
Owner
nfarina commented Mar 1, 2011

Awesome, this is great! Much better API for consumers and matches Apple's error pattern. Merged.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.