So basically, I read in two XML documents. The first has two values ββthat must be saved: name and value. The second has four meanings: Name, DefaultValue, Type and Limit. When reading in documents, I want to store them in some object. I should be able to then combine the two objects into one, which stores 5 values. XML documents vary in length, but the second will always be on top compared to the first.
Example:
<XML1> <Item1> <Name>Cust_No</Name> <Value>10001</Value> </Item1> <Item4> ITEM4 NAME AND VALUE </Item4> <Item7> ITEM 7 NAME AND VALUE </Item7> </XML1> <XML2> <Item1> <Name>Cust_No</Name> <DefaultValue></DefaultValue> <Type>varchar</Type> <Limit>15</Limit> </Item1> 6 MORE TIMES ITEMS 2-7 </XML2>
I already have a code loop through XML. I really need thoughts on how best to store data. Ultimately, I want to be able to join two objects in Key Name. I tried string[] and arrayList[] , but I ran into difficulties combining them. I also read in Dictionary , but also could not implement this (I have never used Dictionary before).
source share