Export info for scan in CSV format

@param int $appId
@param int $scanId
@param string $outFile
@param array $queryParams
@return BaseResponse
7801
public function exportCsv($appId, $scanId, $outFile, array $queryParams = [])
    {
        $response = $this->api
            ->applications()
            ->scans()
            ->exports()
            ->exportCsv($appId, $scanId, $outFile, $queryParams);

        return new BaseResponse($response);
    }
103837
public static long exportCSV(final File out, final Connection conn, final String querySQL, final Collection<String> selectColumnNames, final long offset,
            final long count, final boolean writeTitle, final boolean quoted) throws UncheckedSQLException, UncheckedIOException {
        final NamedSQL namedSQL = NamedSQL.parse(querySQL);
        PreparedStatement stmt = null;

        try {
            stmt = conn.prepareStatement(namedSQL.getPureSQL(), ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_READ_ONLY);
            stmt.setFetchSize(200);

            return exportCSV(out, stmt, selectColumnNames, offset, count, writeTitle, quoted);
        } catch (SQLException e) {
            throw new UncheckedSQLException(e);
        } finally {
            JdbcUtil.closeQuietly(stmt);
        }
    }
1206708
public Collection<Deployment> list(long applicationId, List<String> queryParams)
    {
        return HTTP.GET(String.format("/v2/applications/%d/deployments.json", applicationId), null, queryParams, DEPLOYMENTS).get();
    }
647897
public function deleteAll($appId, array $queryParams = [])
    {
        $response = $this->api->applications()->uploads()->deleteAll($appId, $queryParams);

        return new BaseResponse($response);
    }
1097306
public function getById($appId, array $queryParams = [])
    {
        $response = $this->api->applications()->getById($appId, $queryParams);

        return new ApplicationResponse($response);
    }
1256067
public function getQueuedPdf($appId, $scanId, $queueId, array $queryParams = [])
    {
        $response = $this->client->get($this->uri($appId, $scanId, 'pdfs') . '/queues/' . $queueId, [
            'query' => $queryParams,
        ]);

        return $this->handleResponse($response);
    }
395565
private function listEntityIdsWithoutCps(PagerInterface $pager = null, array $query_params = []): array
    {
        $query_params = [
                'expand' => 'false',
            ] + $query_params;

        $uri = $this->getBaseEndpointUri()->withQuery(http_build_query($query_params));
        $response = $this->getClient()->get($uri);

        $ids = $this->responseToArray($response);

        // Re-key the array from 0 if CPS had to be simulated.
        return $pager ? array_values($this->simulateCpsPagination($pager, $ids)) : $ids;
    }
1345871
public function create($appId, $scanId, $input, array $queryParams = [])
    {
        $response = $this->api
            ->applications()
            ->scans()
            ->classes()
            ->create($appId, $scanId, $input->toArray(), $queryParams);

        return new CustomClassResponse($response);
    }
79494
function out($pagesize, $useinitialsbar, $downloadhelpbutton='') {
        global $DB;
        if (!$this->columns) {
            $onerow = $DB->get_record_sql("SELECT {$this->sql->fields} FROM {$this->sql->from} WHERE {$this->sql->where}",
                $this->sql->params, IGNORE_MULTIPLE);
            //if columns is not set then define columns as the keys of the rows returned
            //from the db.
            $this->define_columns(array_keys((array)$onerow));
            $this->define_headers(array_keys((array)$onerow));
        }
        $this->setup();
        $this->query_db($pagesize, $useinitialsbar);
        $this->build_table();
        $this->close_recordset();
        $this->finish_output();
    }
1231202
public function getById($appId, $profileId, array $queryParams = [])
    {
        $response = $this->api->applications()->profiles()->getById($appId, $profileId, $queryParams);

        return new ProfileResponse($response);
    }
178308
@Override
	public synchronized RecordScan read(int scanId) throws DatabaseException {
    	SqlPreparedStatementWrapper psRead = null;
        try {
        	psRead = DbSQL.getSingleton().getPreparedStatement("scan.ps.read");
			psRead.getPs().setInt(1, scanId);
			
			try (ResultSet rs = psRead.getPs().executeQuery()) {
				return build(rs);
			}
		} catch (SQLException e) {
			throw new DatabaseException(e);
		} finally {
			DbSQL.getSingleton().releasePreparedStatement(psRead);
		}
	}
130800
@Override
	public synchronized RecordScan read(int scanId) throws DatabaseException {
		try {
			psRead.setInt(1, scanId);
			
			try (ResultSet rs = psRead.executeQuery()) {
				RecordScan result = build(rs);
				return result;
			}
		} catch (SQLException e) {
			throw new DatabaseException(e);
		}
	}
194057
public function getAll($appId, $scanId, array $queryParams = [])
    {
        $response = $this->api
            ->applications()
            ->scans()
            ->files()
            ->getAll($appId, $scanId, $queryParams);

        return new FilesResponse($response);
    }
1261523
public function getAll($appId, $scanId, array $queryParams = [])
    {
        $response = $this->api
            ->applications()
            ->scans()
            ->classes()
            ->getAll($appId, $scanId, $queryParams);

        return new CustomClassesResponse($response);
    }
301024
public function getAll($appId, array $queryParams = [])
    {
        $response = $this->api->applications()->acls()->getAll($appId, $queryParams);

        return new AclsResponse($response);
    }
534977
public function getAll($appId, $scanId, $issueId, array $queryParams = [])
    {
        $response = $this->api
            ->applications()
            ->scans()
            ->issues()
            ->patches()
            ->getAll($appId, $scanId, $issueId, $queryParams);

        return new PatchesResponse($response);
    }
1027324
private static List<String[]> exportQueryPageCommentsAsCsv(ReplierExportStrategy replierExportStrategy, QueryPage queryPage, ReportPageCommentProcessor processor) {
    QueryQuestionCommentDAO queryQuestionCommentDAO = new QueryQuestionCommentDAO();
    List<String[]> rows = new ArrayList<>();

    processor.processComments();
    List<QueryQuestionComment> rootComments = processor.getRootComments();
    
    if (rootComments != null && !rootComments.isEmpty()) {
      Map<Long, List<QueryQuestionComment>> childCommentMap = queryQuestionCommentDAO.listTreesByQueryPage(queryPage);
      
      for (QueryQuestionComment rootComment : rootComments) {
        String rootUser = getReplierExportStrategyValue(replierExportStrategy, rootComment.getQueryReply());
        String rootLabel = processor.getCommentLabel(rootComment.getId());
        rows.add(new String[] { rootUser, rootLabel, rootComment.getComment(), "" });
        List<QueryQuestionComment> childComments = childCommentMap.get(rootComment.getId());
        if (childComments != null) {
          childComments.forEach(childComment -> {
            String childUser = getReplierExportStrategyValue(replierExportStrategy, childComment.getQueryReply());
            rows.add(new String[] { childUser, "", "", childComment.getComment() });
          });
        }
      }
    }
    
    return rows;
  }