class Media extends Resource (View source)

The "media" collection of methods.

Typical usage is:

 $displayvideoService = new Google\Service\DisplayVideo(...);
 $media = $displayvideoService->media;

Methods

download(string $resourceName, array $optParams = [])

Downloads media. Download is supported on the URI /download/{resource_name=**}?alt=media. Note: Download requests will not be successful without including alt=media query string.

upload(string $resourceName, GoogleBytestreamMedia $postBody, array $optParams = [])

Uploads media. Upload is supported on the URI /upload/media/{resource_name=**}?upload_type=media. Note: Upload requests will not be successful without including upload_type=media query string. (media.upload)

Details

GoogleBytestreamMedia download(string $resourceName, array $optParams = [])

Downloads media. Download is supported on the URI /download/{resource_name=**}?alt=media. Note: Download requests will not be successful without including alt=media query string.

(media.download)

Parameters

string $resourceName

Name of the media that is being downloaded. See ReadRequest.resource_name.

array $optParams

Optional parameters.

Return Value

GoogleBytestreamMedia

Exceptions

Exception

GoogleBytestreamMedia upload(string $resourceName, GoogleBytestreamMedia $postBody, array $optParams = [])

Uploads media. Upload is supported on the URI /upload/media/{resource_name=**}?upload_type=media. Note: Upload requests will not be successful without including upload_type=media query string. (media.upload)

Parameters

string $resourceName

Name of the media that is being downloaded. See ReadRequest.resource_name.

GoogleBytestreamMedia $postBody
array $optParams

Optional parameters.

Return Value

GoogleBytestreamMedia

Exceptions

Exception