Hi guys! I wanna create a "Tree" for reading *xml files. Can't figure out how many and what kind of links and data i should have into my structure "XML_Tree". Here what i think, but this this don't wanna work or i can't realize it right. So here a peace of "code".
So here is the idea how this structure should work. Every XML_Tree node points to tag in *xml file. *parent is pointing to tag which current tag belong to. So very firstTag doesn't has parent. It will be our "root". *firstChild and *nextChild points to all subTags of our current tag. The difference between them is that one of them needs for pointing to the very first "subTag" and the other one needs for going through our list of children. *firstAtr and *nextAtr has the same meaning but for atributes of xml tag. Will this structure work right? Cause i can't realise it and thought may be my structure is wrong. Sorry for my poor English and the same programming skill. Learning...
Cause i can't realise it and thought may be my structure is wrong
I meant that i have mess into my structure when i am trying execute my programm. And didn't know it is because of invalid structure or wrong pointers assignments.
If you can't use the STL then create your own container class and use it.
So create a list and test it, after you think it works use it with your tree.
after wcsncpy function buffer is filling with china symbols after word that was copied. So buffer is created with more length than i wanted. It doesn't happen every time. What does it depend of?