jeudi 6 septembre 2018

Creating model based on file

I have a question, is it possible and how to create model based on my file? For example -> I created application.properties file where I have 2 properties like: name.type: STRING and name.value: JOHN. What I want to do is creating an object based on it which is like a simple pojo which has properties which I have already defined. Of course I would like to easily change my file and add another field which could be easily converted just as this one. I have already read sth about reflection API in Java, however I am still unable to come up with an idea how to do it. Do you know any solutions to my problem?





Aucun commentaire:

Enregistrer un commentaire