class Response {
String [] [] data;
String [] fields;
// other stuff
}
Now, when you de-serialize this, you would need to figure how to index
your data.
So, let's add these into your "Response" class:
public String[] getFieldNames() { return fields; }
public int getFieldIndexForName(String fieldName) {
// iterate over 'fields' array, return the index of field found
// or -1 if it wasn't
}
public String getField(int dataRow, int fieldIndex) {
return data[dataRow][fieldIndex];