0

I need to set the name of an instance of a class dynamically.

GetDataPoint "This Name has to be dinamically" = new GetDataPoint();

I need dynamic numbers of instances of this class GetDataPoint. Can anyone help please?

Jops
  • 22,535
  • 13
  • 46
  • 63
CoObri
  • 13
  • 5

1 Answers1

1

An example:

ArrayList<GetDataPoint> data = new ArrayList<GetDataPoint>();
int amountOfData = 5;

for(int i = 0; i <= amountOfData; i++) {
data.add(new GetDataPoint());
}

Loop over the data list to retrieve the GetDataPoints.

D. Wonnink
  • 306
  • 4
  • 19