Source:
public String getFeedbackSessionResultsSummaryInSectionAsCsv( String feedbackSessionName, String courseId, String userEmail, String section, String filterText, boolean isMissingResponsesShown, boolean isStatsShown) throws EntityDoesNotExistException, ExceedingRangeException { long indicatedRange = section == null ? 8000 : -1; FeedbackSessionResultsBundle results = getFeedbackSessionResultsForInstructorInSectionWithinRangeFromView( feedbackSessionName, courseId, userEmail, section, indicatedRange, Const.FeedbackSessionResults.QUESTION_SORT_TYPE); if (!results.isComplete) { throw new ExceedingRangeException(ERROR_NUMBER_OF_RESPONSES_EXCEEDS_RANGE); } Collections.sort(results.responses, results.compareByGiverRecipientQuestion); StringBuilder exportBuilder = new StringBuilder(100); exportBuilder.append(String.format("Course,%s", SanitizationHelper.sanitizeForCsv(results.feedbackSession.getCourseId()))) .append(Const.EOL) .append(String.format("Session Name,%s", SanitizationHelper.sanitizeForCsv(results.feedbackSession.getFeedbackSessionName()))) .append(Const.EOL); if (section != null) { exportBuilder.append(String.format("Section Name,%s", SanitizationHelper.sanitizeForCsv(section))) .append(Const.EOL); } exportBuilder.append(Const.EOL).append(Const.EOL); Set<Entry<FeedbackQuestionAttributes, List<FeedbackResponseAttributes>>> entrySet = results.getQuestionResponseMap().entrySet(); if (filterText != null && !filterText.isEmpty()) { entrySet = filterQuestions(entrySet, filterText.toLowerCase()); } for (Map.Entry<FeedbackQuestionAttributes, List<FeedbackResponseAttributes>> entry : entrySet) { exportBuilder.append(getFeedbackSessionResultsForQuestionInCsvFormat( results, entry, isMissingResponsesShown, isStatsShown)); } return exportBuilder.toString(); }

Target:
public String getFeedbackSessionResultsSummaryInSectionAsCsv( String feedbackSessionName, String courseId, String userEmail, String section, String filterText, boolean isMissingResponsesShown, boolean isStatsShown) throws EntityDoesNotExistException, ExceedingRangeException { long indicatedRange = section == null ? INSTRUCTOR_RESPONSE_LIMIT : -1; FeedbackSessionResultsBundle results = getFeedbackSessionResultsForInstructorInSectionWithinRangeFromView( feedbackSessionName, courseId, userEmail, section, indicatedRange, Const.FeedbackSessionResults.QUESTION_SORT_TYPE); if (!results.isComplete) { throw new ExceedingRangeException(ERROR_NUMBER_OF_RESPONSES_EXCEEDS_RANGE); } Collections.sort(results.responses, results.compareByGiverRecipientQuestion); StringBuilder exportBuilder = new StringBuilder(100); exportBuilder.append(String.format("Course,%s", SanitizationHelper.sanitizeForCsv(results.feedbackSession.getCourseId()))) .append(Const.EOL) .append(String.format("Session Name,%s", SanitizationHelper.sanitizeForCsv(results.feedbackSession.getFeedbackSessionName()))) .append(Const.EOL); if (section != null) { exportBuilder.append(String.format("Section Name,%s", SanitizationHelper.sanitizeForCsv(section))) .append(Const.EOL); } exportBuilder.append(Const.EOL).append(Const.EOL); Set<Entry<FeedbackQuestionAttributes, List<FeedbackResponseAttributes>>> entrySet = results.getQuestionResponseMap().entrySet(); if (filterText != null && !filterText.isEmpty()) { entrySet = filterQuestions(entrySet, filterText.toLowerCase()); } for (Map.Entry<FeedbackQuestionAttributes, List<FeedbackResponseAttributes>> entry : entrySet) { exportBuilder.append(getFeedbackSessionResultsForQuestionInCsvFormat( results, entry, isMissingResponsesShown, isStatsShown)); } return exportBuilder.toString(); }