Ok, so I’ve finally decided on how to load my data I’m going to go with loading my book data as an XML file. The problem is that I’m not too sure on where to start, I’ve heard terms such ‘parsing’ but dont know how exactly it fits in.
I have added the code below if someone could give me a start in the right direction I would really appreciate that, to begin with all I want to do is load one line with my own comment under that and then the next line and so on.
<myBook>
− <chapter index="1" name="Chapter Name">
<line index="1" text="line text here"/>
<line index="2" text=" line text here "/>
<line index="3" text=" line text here "/>
<line index="4" text=" line text here "/>
<line index="5" text=" line text here "/>
<line index="6" text=" line text here "/>
<line index="7" text=" line text here "/>
</chapter>
Thanks guys,
Maybe this questions helps you: Navigating XML from Objective-C
There a some classes with which you can process your XML file. If you don’t know about XML in general, read the Wikipedia article about XML. The most common techniques that are used to process XML are also described there.