Ads API .NET library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Google.Api.Ads.Common.Util.Reports.ReportResponse Class Reference

Represents a report response from the server. More...

Inheritance diagram for Google.Api.Ads.Common.Util.Reports.ReportResponse:

Public Member Functions

delegate void OnDownloadSuccessCallback (byte[] contents)
 Delegate to be triggered when asynchronous report download is completed successfully. More...
 
delegate void OnSaveSuccessCallback ()
 Delegate to be triggered when asynchronous report save is completed successfully. More...
 
delegate void OnFailedCallback (AdsReportsException exception)
 Delegate to be triggered when asynchronous report download fails. More...
 
 ReportResponse (WebResponse response)
 Initializes a new instance of the ReportResponse class. More...
 
void Save (string path)
 Saves the report to a specified path and closes the underlying stream. More...
 
void SaveAsync (string path)
 Saves the report to a specified path asynchronously and closes the underlying stream. OnSaveSuccess callback will be triggered when the download completes successfully, and OnFailed callback will be triggered when the download fails. More...
 
byte[] Download ()
 Downloads the report to memory and closes the underlying stream. More...
 
void DownloadAsync ()
 Downloads the report to memory asynchronously and closes the underlying stream. OnDownloadSuccess callback will be triggered when the download completes successfully, and OnFailed callback will be triggered when the download fails. More...
 
void Dispose ()
 Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. More...
 

Protected Member Functions

virtual void Dispose (bool disposing)
 Releases unmanaged and - optionally - managed resources. More...
 

Properties

OnDownloadSuccessCallback OnDownloadSuccess [get, set]
 The callback that will be triggered when the asynchronous report download is completed successfully. More...
 
OnSaveSuccessCallback OnSaveSuccess [get, set]
 The callback that will be triggered when the asynchronous report save is completed successfully. More...
 
OnFailedCallback OnFailed [get, set]
 Gets the callback that will be triggered when the asynchronous report download fails. More...
 
Stream Stream [get]
 Gets the report contents as a stream. More...
 
Stream DecompressedStream [get]
 Gets the report contents as a decompressed stream. More...
 
string Path [get, set]
 Gets the path to the downloaded report. More...
 

Detailed Description

Represents a report response from the server.

Constructor & Destructor Documentation

Google.Api.Ads.Common.Util.Reports.ReportResponse.ReportResponse ( WebResponse  response)
inline

Initializes a new instance of the ReportResponse class.

Parameters
responseThe underlying HTTP web response.

Member Function Documentation

void Google.Api.Ads.Common.Util.Reports.ReportResponse.Dispose ( )
inline

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

virtual void Google.Api.Ads.Common.Util.Reports.ReportResponse.Dispose ( bool  disposing)
inlineprotectedvirtual

Releases unmanaged and - optionally - managed resources.

Parameters
disposingtrue to release both managed and unmanaged resources; false to release only unmanaged resources.
byte [] Google.Api.Ads.Common.Util.Reports.ReportResponse.Download ( )
inline

Downloads the report to memory and closes the underlying stream.

Exceptions
AdsReportsExceptionIf there was an error downloading the report.
void Google.Api.Ads.Common.Util.Reports.ReportResponse.DownloadAsync ( )
inline

Downloads the report to memory asynchronously and closes the underlying stream. OnDownloadSuccess callback will be triggered when the download completes successfully, and OnFailed callback will be triggered when the download fails.

Exceptions
AdsReportsExceptionIf there was an error downloading the report.
delegate void Google.Api.Ads.Common.Util.Reports.ReportResponse.OnDownloadSuccessCallback ( byte[]  contents)

Delegate to be triggered when asynchronous report download is completed successfully.

delegate void Google.Api.Ads.Common.Util.Reports.ReportResponse.OnFailedCallback ( AdsReportsException  exception)

Delegate to be triggered when asynchronous report download fails.

delegate void Google.Api.Ads.Common.Util.Reports.ReportResponse.OnSaveSuccessCallback ( )

Delegate to be triggered when asynchronous report save is completed successfully.

void Google.Api.Ads.Common.Util.Reports.ReportResponse.Save ( string  path)
inline

Saves the report to a specified path and closes the underlying stream.

Parameters
pathThe path to which report is saved.
Exceptions
AdsReportsExceptionIf there was an error saving the report.
void Google.Api.Ads.Common.Util.Reports.ReportResponse.SaveAsync ( string  path)
inline

Saves the report to a specified path asynchronously and closes the underlying stream. OnSaveSuccess callback will be triggered when the download completes successfully, and OnFailed callback will be triggered when the download fails.

Parameters
pathThe path to which report is saved.
Exceptions
AdsReportsExceptionIf there was an error saving the report.

Property Documentation

Stream Google.Api.Ads.Common.Util.Reports.ReportResponse.DecompressedStream
get

Gets the report contents as a decompressed stream.

OnDownloadSuccessCallback Google.Api.Ads.Common.Util.Reports.ReportResponse.OnDownloadSuccess
getset

The callback that will be triggered when the asynchronous report download is completed successfully.

OnFailedCallback Google.Api.Ads.Common.Util.Reports.ReportResponse.OnFailed
getset

Gets the callback that will be triggered when the asynchronous report download fails.

OnSaveSuccessCallback Google.Api.Ads.Common.Util.Reports.ReportResponse.OnSaveSuccess
getset

The callback that will be triggered when the asynchronous report save is completed successfully.

string Google.Api.Ads.Common.Util.Reports.ReportResponse.Path
getset

Gets the path to the downloaded report.

Stream Google.Api.Ads.Common.Util.Reports.ReportResponse.Stream
get

Gets the report contents as a stream.


The documentation for this class was generated from the following file: