// totally new query here.
final HashMap newParams = new HashMap();
queryCache.put(query, newParams);
final Parameters params = new Parameters(parameters);
final ReportData newData = backend.queryData(query, params);
newParams.put(params, newData);
newData.setCursorPosition(ReportData.BEFORE_FIRST_ROW);
return newData;
}
else
{
// Lookup the parameters ...
final Parameters params = new Parameters(parameters);
final ReportData data = (ReportData) parameterCache.get(params);
if (data != null)
{
data.setCursorPosition(ReportData.BEFORE_FIRST_ROW);
return data;
}
final ReportData newData = backend.queryData(query, params);
parameterCache.put(params, newData);
newData.setCursorPosition(ReportData.BEFORE_FIRST_ROW);
return newData;
}
}
catch (DataSourceException e)
{