I need to create class that should return object which is build from this attributes
Object object;
String Name;
String ChildName;
String TagName;
The problem here is that I need to return list i.e.
In the list for every object there is name,child … strings.
How can I do that in java?
I think you are asking a method that returns List of object with given parameters.Then you can create your class as shown below :
Then in the other method where you want to return list you can use it as shown :