Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

guydor

macrumors member
Original poster
Mar 10, 2009
67
0
Hello,

I would like to know what is the best way to represent objects such as cloths.
Let's say in the app you can create your own character, assign mouth, eyes, nose, cloths etc.

How can I represent this objects in storage?
XML file with the required properties and when need, parse the XML file?

Thanks!
 

dejo

Moderator emeritus
Sep 2, 2004
15,982
452
The Centennial State
How can I represent this objects in storage?
XML file with the required properties and when need, parse the XML file?

In storage, within your app? If so, an XML file is probably a bit too cumbersome. You might want to look into using property-lists (which are, in essence, XML files too, but with a helpful API) or CoreData instead, and then probably backing that up with some model classes. I recommend you read the "Core App Objects" section of the iOS App Programming Guide as a start.
 

guydor

macrumors member
Original poster
Mar 10, 2009
67
0
Great Thanks!

In storage, within your app? If so, an XML file is probably a bit too cumbersome. You might want to look into using property-lists (which are, in essence, XML files too, but with a helpful API) or CoreData instead, and then probably backing that up with some model classes. I recommend you read the "Core App Objects" section of the iOS App Programming Guide as a start.

:)
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.