I have a problem.
I am using the XMLReader class to get a NSDictionary
and everything works fine. But i can't to get the values of the atributes of my productData element.
Specifically, I have the following NSDictionary
:
{
response = {
products = {
productsData = (
{
alias = "Product 1";
id = 01;
price = "10";
},
{
alias = "Product 2";
id = 02;
price = "20";
},
{
alias = "Product 3";
id = 03;
price = "30";
});
};
};
}
I used this code to create de NSDictionary
:
NSDictionary *dictionary = [XMLReader dictionaryForXMLData:responseData error:&parseError];
and responseData contains:
<application>
<products>
<productData>
<id>01</id>
<price>10</price>
<alias>Product 1</alias>
</productData>
<productData>
<id>02</id>
<price>20</price>
<alias>Product 2</alias>
</productData>
<productData>
<id>02</id>
<price>20</price>
<alias>Product 3</alias>
</productData>
</products>
</application>
Then, i don't know how get the values of each productData like id, price and alias...
Anybody know how to do it??
Thanks and please forgive my bad english !