Reputation: 694
I am using following code for applying delegate for XML Parsing
NSXMLParser *nsXMLParse = [[NSXMLParser alloc] initWithData:data];
XMLParse *parser = [[XMLParse alloc] initXMLParser];//XMLParse is my custom class, where i used the NSXMLParser protocol
[nsXMLParse setDelegate:(id <NSXMLParserDelegate>)parser];
But this is not working properly. Although its not giving any error here, but its Giving "signal SIGABRT" Error, while Compiling. So please help.
My XML is:
<?xml version="1.0" encoding="UTF-8"?>
<Users>
<User name="Some One" id="[email protected]" pass="123"/>
</Users>
Upvotes: 0
Views: 158
Reputation: 7381
You don't need to cast to id if XMLParse class implements the NSXMLParserDelegate protocol.
Upvotes: 1