Google_PlayersServiceResource

The "players" collection of methods.

Defined (2)

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

/src/contrib/Google_GamesManagementService.php  
  1. class Google_PlayersServiceResource extends Google_ServiceResource { 
  2.  
  3. /** 
  4. * Hide the given player's leaderboard scores from the given application. This method is only 
  5. * available to user accounts for your developer console. (players.hide) 
  6. * @param string $applicationId The application being requested. 
  7. * @param string $playerId A player ID. A value of me may be used in place of the authenticated player's ID. 
  8. * @param array $optParams Optional parameters. 
  9. */ 
  10. public function hide($applicationId, $playerId, $optParams = array()) { 
  11. $params = array('applicationId' => $applicationId, 'playerId' => $playerId); 
  12. $params = array_merge($params, $optParams); 
  13. $data = $this->__call('hide', array($params)); 
  14. return $data; 
  15. /** 
  16. * Unhide the given player's leaderboard scores from the given application. This method is only 
  17. * available to user accounts for your developer console. (players.unhide) 
  18. * @param string $applicationId The application being requested. 
  19. * @param string $playerId A player ID. A value of me may be used in place of the authenticated player's ID. 
  20. * @param array $optParams Optional parameters. 
  21. */ 
  22. public function unhide($applicationId, $playerId, $optParams = array()) { 
  23. $params = array('applicationId' => $applicationId, 'playerId' => $playerId); 
  24. $params = array_merge($params, $optParams); 
  25. $data = $this->__call('unhide', array($params)); 
  26. return $data; 
/src/contrib/Google_GamesService.php  
  1. class Google_PlayersServiceResource extends Google_ServiceResource { 
  2.  
  3. /** 
  4. * Retrieves the Player resource with the given ID. To retrieve the player for the currently 
  5. * authenticated user, set playerId to me. (players.get) 
  6. * @param string $playerId A player ID. A value of me may be used in place of the authenticated player's ID. 
  7. * @param array $optParams Optional parameters. 
  8. * @return Google_Player 
  9. */ 
  10. public function get($playerId, $optParams = array()) { 
  11. $params = array('playerId' => $playerId); 
  12. $params = array_merge($params, $optParams); 
  13. $data = $this->__call('get', array($params)); 
  14. if ($this->useObjects()) { 
  15. return new Google_Player($data); 
  16. } else { 
  17. return $data;