google_AdunitsServiceResource

The "adunits" collection of methods.

Defined (1)

The class is defined in the following location(s).

/google-api-php-client/src/contrib/Google_AdExchangeSellerService.php  
  1. class google_AdunitsServiceResource extends Google_ServiceResource { 
  2.  
  3. /** 
  4. * Gets the specified ad unit in the specified ad client. (adunits.get) 
  5. * @param string $adClientId Ad client for which to get the ad unit. 
  6. * @param string $adUnitId Ad unit to retrieve. 
  7. * @param array $optParams Optional parameters. 
  8. * @return google_AdUnit 
  9. */ 
  10. public function get($adClientId, $adUnitId, $optParams = array()) { 
  11. $params = array('adClientId' => $adClientId, 'adUnitId' => $adUnitId); 
  12. $params = array_merge($params, $optParams); 
  13. $data = $this->__call('get', array($params)); 
  14. if ($this->useObjects()) { 
  15. return new google_AdUnit($data); 
  16. } else { 
  17. return $data; 
  18. /** 
  19. * List all ad units in the specified ad client for this Ad Exchange account. 
  20. * (adunits.list) 
  21. * @param string $adClientId Ad client for which to list ad units. 
  22. * @param array $optParams Optional parameters. 
  23. * @opt_param bool includeInactive Whether to include inactive ad units. Default: true. 
  24. * @opt_param string maxResults The maximum number of ad units to include in the response, used for paging. 
  25. * @opt_param string pageToken A continuation token, used to page through ad units. To retrieve the next page, set this parameter to the value of "nextPageToken" from the previous response. 
  26. * @return google_AdUnits 
  27. */ 
  28. public function listAdunits($adClientId, $optParams = array()) { 
  29. $params = array('adClientId' => $adClientId); 
  30. $params = array_merge($params, $optParams); 
  31. $data = $this->__call('list', array($params)); 
  32. if ($this->useObjects()) { 
  33. return new google_AdUnits($data); 
  34. } else { 
  35. return $data;