0

I have a configuration file with below details :

<app>
<domain name="temp1" value=123/>
<domain name="temp2" value=455/>
</app>

in my code, I store value based on name. like if temp1 is the name,store value in column1 of table. if temp2 is the name, store value in column2 of table. I want to create multiple instances of domain based on value in configuration file, any suggestions on how to do this.

Priyanka
  • 51
  • 1
  • 1
  • 9
  • Create a Domain class, parse the file, instance a new Domain per each domain tag in your file. Include " in all your attributes.not only in those that represent a String. – RubioRic Apr 26 '16 at 05:19
  • My answer to another Stack overview question might provide some inspiration: http://stackoverflow.com/questions/31330782/how-to-handle-large-number-of-configuration-parameters-across-a-program-conceptu/31351052#31351052 – Ciaran McHale Apr 27 '16 at 19:36

0 Answers0