I have data of the form
ith entry = string1, string2....fixed number N of strings,
(name1, name2,....variable number of strings)
i.e. it is a list of (N strings and a list of variable size)
I currently have List<List<String>>
and I'm thinking just treat the N+1th
to the last string differently...but is there a better way to represent this data? Specifically I'd like to be able to interact with (name1, name2...) as a list rather than as strings
A wrapper like this may be used:
Class MyData
{
private String[] fixedData;
private List<String> variableData;
public MyData(int fixedSizeN) {
fixedData = new String[fixedSizeN];
variableData = new ArrayList<String>();
}
//public get/set go here
}
List<MyData> comboData;