SemanticTile.php 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215
  1. <?php
  2. /*
  3. * Copyright 2014 Google Inc.
  4. *
  5. * Licensed under the Apache License, Version 2.0 (the "License"); you may not
  6. * use this file except in compliance with the License. You may obtain a copy of
  7. * the License at
  8. *
  9. * http://www.apache.org/licenses/LICENSE-2.0
  10. *
  11. * Unless required by applicable law or agreed to in writing, software
  12. * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  13. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  14. * License for the specific language governing permissions and limitations under
  15. * the License.
  16. */
  17. namespace Google\Service;
  18. use Google\Client;
  19. /**
  20. * Service definition for SemanticTile (v1).
  21. *
  22. * <p>
  23. * Serves vector tiles containing geospatial data.</p>
  24. *
  25. * <p>
  26. * For more information about this service, see the API
  27. * <a href="https://developers.google.com/maps/contact-sales/" target="_blank">Documentation</a>
  28. * </p>
  29. *
  30. * @author Google, Inc.
  31. */
  32. class SemanticTile extends \Google\Service
  33. {
  34. public $featuretiles;
  35. public $terraintiles;
  36. /**
  37. * Constructs the internal representation of the SemanticTile service.
  38. *
  39. * @param Client|array $clientOrConfig The client used to deliver requests, or a
  40. * config array to pass to a new Client instance.
  41. * @param string $rootUrl The root URL used for requests to the service.
  42. */
  43. public function __construct($clientOrConfig = [], $rootUrl = null)
  44. {
  45. parent::__construct($clientOrConfig);
  46. $this->rootUrl = $rootUrl ?: 'https://vectortile.googleapis.com/';
  47. $this->servicePath = '';
  48. $this->batchPath = 'batch';
  49. $this->version = 'v1';
  50. $this->serviceName = 'vectortile';
  51. $this->featuretiles = new SemanticTile\Resource\Featuretiles(
  52. $this,
  53. $this->serviceName,
  54. 'featuretiles',
  55. [
  56. 'methods' => [
  57. 'get' => [
  58. 'path' => 'v1/{+name}',
  59. 'httpMethod' => 'GET',
  60. 'parameters' => [
  61. 'name' => [
  62. 'location' => 'path',
  63. 'type' => 'string',
  64. 'required' => true,
  65. ],
  66. 'alwaysIncludeBuildingFootprints' => [
  67. 'location' => 'query',
  68. 'type' => 'boolean',
  69. ],
  70. 'clientInfo.apiClient' => [
  71. 'location' => 'query',
  72. 'type' => 'string',
  73. ],
  74. 'clientInfo.applicationId' => [
  75. 'location' => 'query',
  76. 'type' => 'string',
  77. ],
  78. 'clientInfo.applicationVersion' => [
  79. 'location' => 'query',
  80. 'type' => 'string',
  81. ],
  82. 'clientInfo.deviceModel' => [
  83. 'location' => 'query',
  84. 'type' => 'string',
  85. ],
  86. 'clientInfo.operatingSystem' => [
  87. 'location' => 'query',
  88. 'type' => 'string',
  89. ],
  90. 'clientInfo.platform' => [
  91. 'location' => 'query',
  92. 'type' => 'string',
  93. ],
  94. 'clientInfo.userId' => [
  95. 'location' => 'query',
  96. 'type' => 'string',
  97. ],
  98. 'clientTileVersionId' => [
  99. 'location' => 'query',
  100. 'type' => 'string',
  101. ],
  102. 'enableDetailedHighwayTypes' => [
  103. 'location' => 'query',
  104. 'type' => 'boolean',
  105. ],
  106. 'enableFeatureNames' => [
  107. 'location' => 'query',
  108. 'type' => 'boolean',
  109. ],
  110. 'enableModeledVolumes' => [
  111. 'location' => 'query',
  112. 'type' => 'boolean',
  113. ],
  114. 'enablePoliticalFeatures' => [
  115. 'location' => 'query',
  116. 'type' => 'boolean',
  117. ],
  118. 'enablePrivateRoads' => [
  119. 'location' => 'query',
  120. 'type' => 'boolean',
  121. ],
  122. 'enableUnclippedBuildings' => [
  123. 'location' => 'query',
  124. 'type' => 'boolean',
  125. ],
  126. 'languageCode' => [
  127. 'location' => 'query',
  128. 'type' => 'string',
  129. ],
  130. 'regionCode' => [
  131. 'location' => 'query',
  132. 'type' => 'string',
  133. ],
  134. ],
  135. ],
  136. ]
  137. ]
  138. );
  139. $this->terraintiles = new SemanticTile\Resource\Terraintiles(
  140. $this,
  141. $this->serviceName,
  142. 'terraintiles',
  143. [
  144. 'methods' => [
  145. 'get' => [
  146. 'path' => 'v1/{+name}',
  147. 'httpMethod' => 'GET',
  148. 'parameters' => [
  149. 'name' => [
  150. 'location' => 'path',
  151. 'type' => 'string',
  152. 'required' => true,
  153. ],
  154. 'altitudePrecisionCentimeters' => [
  155. 'location' => 'query',
  156. 'type' => 'integer',
  157. ],
  158. 'clientInfo.apiClient' => [
  159. 'location' => 'query',
  160. 'type' => 'string',
  161. ],
  162. 'clientInfo.applicationId' => [
  163. 'location' => 'query',
  164. 'type' => 'string',
  165. ],
  166. 'clientInfo.applicationVersion' => [
  167. 'location' => 'query',
  168. 'type' => 'string',
  169. ],
  170. 'clientInfo.deviceModel' => [
  171. 'location' => 'query',
  172. 'type' => 'string',
  173. ],
  174. 'clientInfo.operatingSystem' => [
  175. 'location' => 'query',
  176. 'type' => 'string',
  177. ],
  178. 'clientInfo.platform' => [
  179. 'location' => 'query',
  180. 'type' => 'string',
  181. ],
  182. 'clientInfo.userId' => [
  183. 'location' => 'query',
  184. 'type' => 'string',
  185. ],
  186. 'maxElevationResolutionCells' => [
  187. 'location' => 'query',
  188. 'type' => 'integer',
  189. ],
  190. 'minElevationResolutionCells' => [
  191. 'location' => 'query',
  192. 'type' => 'integer',
  193. ],
  194. 'terrainFormats' => [
  195. 'location' => 'query',
  196. 'type' => 'string',
  197. 'repeated' => true,
  198. ],
  199. ],
  200. ],
  201. ]
  202. ]
  203. );
  204. }
  205. }
  206. // Adding a class alias for backwards compatibility with the previous class name.
  207. class_alias(SemanticTile::class, 'Google_Service_SemanticTile');