All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.microsoft.bingads.v13.internal.reporting.RowReport Maven / Gradle / Ivy

Go to download

The Bing Ads Java SDK is a library improving developer experience when working with the Bing Ads services by providing high-level access to features such as Bulk API, OAuth Authorization and SOAP API.

There is a newer version: 13.0.22.1
Show newest version
package com.microsoft.bingads.v13.internal.reporting;

import java.io.File;
import java.io.IOException;

import com.microsoft.bingads.v13.reporting.Report;
import com.microsoft.bingads.v13.reporting.ReportFormat;
import com.microsoft.bingads.v13.reporting.ReportRecord;

/**
 * Internal use only.
 *
 */
public class RowReport extends Report {

    private RowReportRecordIterable recordIterable;

    private RowReportStreamReader reportStreamReader;

    public RowReport(File file, ReportFormat format) throws IOException {
        this(new RowReportStreamReader(file, format));
    }

    public RowReport(String filePath, ReportFormat format) throws IOException {
        this(new RowReportStreamReader(filePath, format));
    }

    private RowReport(RowReportStreamReader reportStreamReader) {
        this.reportStreamReader = reportStreamReader;
        this.reportHeader = new RowReportHeader(reportStreamReader);
        this.recordIterable = new RowReportRecordIterable(reportStreamReader);
    }

    @Override
    public Iterable getReportRecords() {
        return recordIterable;
    }

    @Override
    public void close() {
        try {
            if (reportStreamReader != null) {
                reportStreamReader.close();
            }
        } catch (Exception e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy