Google_LeaderboardsServiceResource

The "leaderboards" collection of methods.

Defined (1)

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

/src/contrib/Google_GamesService.php  
  1. class Google_LeaderboardsServiceResource extends Google_ServiceResource { 
  2.  
  3. /** 
  4. * Retrieves the metadata of the leaderboard with the given ID. (leaderboards.get) 
  5. * @param string $leaderboardId The ID of the leaderboard. 
  6. * @param array $optParams Optional parameters. 
  7. * @opt_param string language The preferred language to use for strings returned by this method. 
  8. * @return Google_Leaderboard 
  9. */ 
  10. public function get($leaderboardId, $optParams = array()) { 
  11. $params = array('leaderboardId' => $leaderboardId); 
  12. $params = array_merge($params, $optParams); 
  13. $data = $this->__call('get', array($params)); 
  14. if ($this->useObjects()) { 
  15. return new Google_Leaderboard($data); 
  16. } else { 
  17. return $data; 
  18. /** 
  19. * Lists all the leaderboard metadata for your application. (leaderboards.list) 
  20. * @param array $optParams Optional parameters. 
  21. * @opt_param string language The preferred language to use for strings returned by this method. 
  22. * @opt_param int maxResults The maximum number of leaderboards to return in the response. For any response, the actual number of leaderboards returned may be less than the specified maxResults. 
  23. * @opt_param string pageToken The token returned by the previous request. 
  24. * @return Google_LeaderboardListResponse 
  25. */ 
  26. public function listLeaderboards($optParams = array()) { 
  27. $params = array(); 
  28. $params = array_merge($params, $optParams); 
  29. $data = $this->__call('list', array($params)); 
  30. if ($this->useObjects()) { 
  31. return new Google_LeaderboardListResponse($data); 
  32. } else { 
  33. return $data;