@Override public Object getIndexField(String fieldName) throws IOException { if (currentResult != null) { return decodeIndexFieldFrom(fieldName, currentResult.getRow()); } else if (currentQResult != null) { return currentQResult.getIndexField(fieldName); } else { throw new RuntimeException("QueryResult.getIndexField() is being called but there is no current result."); } }