Google_LocationsServiceResource
The "locations" collection of methods.
Defined (1)
The class is defined in the following location(s).
- /src/contrib/Google_MirrorService.php
- class Google_LocationsServiceResource extends Google_ServiceResource {
- /**
- * Gets a single location by ID. (locations.get)
- *
- * @param string $id The ID of the location or latest for the last known location.
- * @param array $optParams Optional parameters.
- * @return Google_Location
- */
- public function get($id, $optParams = array()) {
- $params = array('id' => $id);
- $params = array_merge($params, $optParams);
- $data = $this->__call('get', array($params));
- if ($this->useObjects()) {
- return new Google_Location($data);
- } else {
- return $data;
- }
- }
- /**
- * Retrieves a list of locations for the user. (locations.list)
- *
- * @param array $optParams Optional parameters.
- * @return Google_LocationsListResponse
- */
- public function listLocations($optParams = array()) {
- $params = array();
- $params = array_merge($params, $optParams);
- $data = $this->__call('list', array($params));
- if ($this->useObjects()) {
- return new Google_LocationsListResponse($data);
- } else {
- return $data;
- }
- }
- }