PageRenderTime 34ms CodeModel.GetById 0ms RepoModel.GetById 0ms app.codeStats 1ms

/webui/google-api/contrib/apiBigqueryService.php

https://bitbucket.org/sailsdigital/piler-remi
PHP | 1741 lines | 1418 code | 52 blank | 271 comment | 34 complexity | c5844fc102162b5fc8e55b2d0580d164 MD5 | raw file
Possible License(s): GPL-3.0

Large files files are truncated, but you can click here to view the full file

  1. <?php
  2. /*
  3. * Copyright (c) 2010 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. /**
  18. * The "tables" collection of methods.
  19. * Typical usage is:
  20. * <code>
  21. * $bigqueryService = new apiBigqueryService(...);
  22. * $tables = $bigqueryService->tables;
  23. * </code>
  24. */
  25. class TablesServiceResource extends apiServiceResource {
  26. /**
  27. * Creates a new, empty table in the dataset. (tables.insert)
  28. *
  29. * @param Table $postBody
  30. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  31. *
  32. * @opt_param string projectId Project ID of the new table
  33. * @opt_param string datasetId Dataset ID of the new table
  34. * @return Table
  35. */
  36. public function insert(Table $postBody, $optParams = array()) {
  37. $params = array('postBody' => $postBody);
  38. $params = array_merge($params, $optParams);
  39. $data = $this->__call('insert', array($params));
  40. if ($this->useObjects()) {
  41. return new Table($data);
  42. } else {
  43. return $data;
  44. }
  45. }
  46. /**
  47. * Gets the specified table resource by table ID. This method does not return the data in the table,
  48. * it only returns the table resource, which describes the structure of this table. (tables.get)
  49. *
  50. * @param string $projectId Project ID of the requested table
  51. * @param string $datasetId Dataset ID of the requested table
  52. * @param string $tableId Table ID of the requested table
  53. * @return Table
  54. */
  55. public function get($projectId, $datasetId, $tableId, $optParams = array()) {
  56. $params = array('projectId' => $projectId, 'datasetId' => $datasetId, 'tableId' => $tableId);
  57. $params = array_merge($params, $optParams);
  58. $data = $this->__call('get', array($params));
  59. if ($this->useObjects()) {
  60. return new Table($data);
  61. } else {
  62. return $data;
  63. }
  64. }
  65. /**
  66. * Lists all tables in the specified dataset. (tables.list)
  67. *
  68. * @param string $projectId Project ID of the tables to list
  69. * @param string $datasetId Dataset ID of the tables to list
  70. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  71. *
  72. * @opt_param string pageToken Page token, returned by a previous call, to request the next page of results
  73. * @opt_param string maxResults Maximum number of results to return
  74. * @return TableList
  75. */
  76. public function listTables($projectId, $datasetId, $optParams = array()) {
  77. $params = array('projectId' => $projectId, 'datasetId' => $datasetId);
  78. $params = array_merge($params, $optParams);
  79. $data = $this->__call('list', array($params));
  80. if ($this->useObjects()) {
  81. return new TableList($data);
  82. } else {
  83. return $data;
  84. }
  85. }
  86. /**
  87. * Updates information in an existing table, specified by tableId. (tables.update)
  88. *
  89. * @param Table $postBody
  90. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  91. *
  92. * @opt_param string projectId Project ID of the table to update
  93. * @opt_param string datasetId Dataset ID of the table to update
  94. * @opt_param string tableId Table ID of the table to update
  95. * @return Table
  96. */
  97. public function update(Table $postBody, $optParams = array()) {
  98. $params = array('postBody' => $postBody);
  99. $params = array_merge($params, $optParams);
  100. $data = $this->__call('update', array($params));
  101. if ($this->useObjects()) {
  102. return new Table($data);
  103. } else {
  104. return $data;
  105. }
  106. }
  107. /**
  108. * Updates information in an existing table, specified by tableId. This method supports patch
  109. * semantics. (tables.patch)
  110. *
  111. * @param string $projectId Project ID of the table to update
  112. * @param string $datasetId Dataset ID of the table to update
  113. * @param string $tableId Table ID of the table to update
  114. * @param Table $postBody
  115. * @return Table
  116. */
  117. public function patch($projectId, $datasetId, $tableId, Table $postBody, $optParams = array()) {
  118. $params = array('projectId' => $projectId, 'datasetId' => $datasetId, 'tableId' => $tableId, 'postBody' => $postBody);
  119. $params = array_merge($params, $optParams);
  120. $data = $this->__call('patch', array($params));
  121. if ($this->useObjects()) {
  122. return new Table($data);
  123. } else {
  124. return $data;
  125. }
  126. }
  127. /**
  128. * Deletes the table specified by tableId from the dataset. If the table contains data, all the data
  129. * will be deleted. (tables.delete)
  130. *
  131. * @param string $projectId Project ID of the table to delete
  132. * @param string $datasetId Dataset ID of the table to delete
  133. * @param string $tableId Table ID of the table to delete
  134. */
  135. public function delete($projectId, $datasetId, $tableId, $optParams = array()) {
  136. $params = array('projectId' => $projectId, 'datasetId' => $datasetId, 'tableId' => $tableId);
  137. $params = array_merge($params, $optParams);
  138. $data = $this->__call('delete', array($params));
  139. return $data;
  140. }
  141. }
  142. /**
  143. * The "datasets" collection of methods.
  144. * Typical usage is:
  145. * <code>
  146. * $bigqueryService = new apiBigqueryService(...);
  147. * $datasets = $bigqueryService->datasets;
  148. * </code>
  149. */
  150. class DatasetsServiceResource extends apiServiceResource {
  151. /**
  152. * Creates a new empty dataset. (datasets.insert)
  153. *
  154. * @param Dataset $postBody
  155. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  156. *
  157. * @opt_param string projectId Project ID of the new dataset
  158. * @return Dataset
  159. */
  160. public function insert(Dataset $postBody, $optParams = array()) {
  161. $params = array('postBody' => $postBody);
  162. $params = array_merge($params, $optParams);
  163. $data = $this->__call('insert', array($params));
  164. if ($this->useObjects()) {
  165. return new Dataset($data);
  166. } else {
  167. return $data;
  168. }
  169. }
  170. /**
  171. * Returns the dataset specified by datasetID. (datasets.get)
  172. *
  173. * @param string $projectId Project ID of the requested dataset
  174. * @param string $datasetId Dataset ID of the requested dataset
  175. * @return Dataset
  176. */
  177. public function get($projectId, $datasetId, $optParams = array()) {
  178. $params = array('projectId' => $projectId, 'datasetId' => $datasetId);
  179. $params = array_merge($params, $optParams);
  180. $data = $this->__call('get', array($params));
  181. if ($this->useObjects()) {
  182. return new Dataset($data);
  183. } else {
  184. return $data;
  185. }
  186. }
  187. /**
  188. * Lists all the datasets in the specified project to which the caller has read access; however, a
  189. * project owner can list (but not necessarily get) all datasets in his project. (datasets.list)
  190. *
  191. * @param string $projectId Project ID of the datasets to be listed
  192. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  193. *
  194. * @opt_param string pageToken Page token, returned by a previous call, to request the next page of results
  195. * @opt_param string maxResults The maximum number of results to return
  196. * @return DatasetList
  197. */
  198. public function listDatasets($projectId, $optParams = array()) {
  199. $params = array('projectId' => $projectId);
  200. $params = array_merge($params, $optParams);
  201. $data = $this->__call('list', array($params));
  202. if ($this->useObjects()) {
  203. return new DatasetList($data);
  204. } else {
  205. return $data;
  206. }
  207. }
  208. /**
  209. * Updates information in an existing dataset, specified by datasetId. Properties not included in
  210. * the submitted resource will not be changed. If you include the access property without any values
  211. * assigned, the request will fail as you must specify at least one owner for a dataset.
  212. * (datasets.update)
  213. *
  214. * @param Dataset $postBody
  215. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  216. *
  217. * @opt_param string projectId Project ID of the dataset being updated
  218. * @opt_param string datasetId Dataset ID of the dataset being updated
  219. * @return Dataset
  220. */
  221. public function update(Dataset $postBody, $optParams = array()) {
  222. $params = array('postBody' => $postBody);
  223. $params = array_merge($params, $optParams);
  224. $data = $this->__call('update', array($params));
  225. if ($this->useObjects()) {
  226. return new Dataset($data);
  227. } else {
  228. return $data;
  229. }
  230. }
  231. /**
  232. * Updates information in an existing dataset, specified by datasetId. Properties not included in
  233. * the submitted resource will not be changed. If you include the access property without any values
  234. * assigned, the request will fail as you must specify at least one owner for a dataset. This method
  235. * supports patch semantics. (datasets.patch)
  236. *
  237. * @param string $projectId Project ID of the dataset being updated
  238. * @param string $datasetId Dataset ID of the dataset being updated
  239. * @param Dataset $postBody
  240. * @return Dataset
  241. */
  242. public function patch($projectId, $datasetId, Dataset $postBody, $optParams = array()) {
  243. $params = array('projectId' => $projectId, 'datasetId' => $datasetId, 'postBody' => $postBody);
  244. $params = array_merge($params, $optParams);
  245. $data = $this->__call('patch', array($params));
  246. if ($this->useObjects()) {
  247. return new Dataset($data);
  248. } else {
  249. return $data;
  250. }
  251. }
  252. /**
  253. * Deletes the dataset specified by datasetId value. Before you can delete a dataset, you must
  254. * delete all its tables, either manually or by specifying deleteContents. Immediately after
  255. * deletion, you can create another dataset with the same name. (datasets.delete)
  256. *
  257. * @param string $projectId Project ID of the dataset being deleted
  258. * @param string $datasetId Dataset ID of dataset being deleted
  259. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  260. *
  261. * @opt_param bool deleteContents If True, delete all the tables in the dataset. If False and the dataset contains tables, the request will fail. Default is False
  262. */
  263. public function delete($projectId, $datasetId, $optParams = array()) {
  264. $params = array('projectId' => $projectId, 'datasetId' => $datasetId);
  265. $params = array_merge($params, $optParams);
  266. $data = $this->__call('delete', array($params));
  267. return $data;
  268. }
  269. }
  270. /**
  271. * The "jobs" collection of methods.
  272. * Typical usage is:
  273. * <code>
  274. * $bigqueryService = new apiBigqueryService(...);
  275. * $jobs = $bigqueryService->jobs;
  276. * </code>
  277. */
  278. class JobsServiceResource extends apiServiceResource {
  279. /**
  280. * Starts a new asynchronous job. (jobs.insert)
  281. *
  282. * @param Job $postBody
  283. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  284. *
  285. * @opt_param string projectId Project ID of the project that will be billed for the job
  286. * @return Job
  287. */
  288. public function insert(Job $postBody, $optParams = array()) {
  289. $params = array('postBody' => $postBody);
  290. $params = array_merge($params, $optParams);
  291. $data = $this->__call('insert', array($params));
  292. if ($this->useObjects()) {
  293. return new Job($data);
  294. } else {
  295. return $data;
  296. }
  297. }
  298. /**
  299. * Retrieves the specified job by ID. (jobs.get)
  300. *
  301. * @param string $projectId Project ID of the requested job
  302. * @param string $jobId Job ID of the requested job
  303. * @return Job
  304. */
  305. public function get($projectId, $jobId, $optParams = array()) {
  306. $params = array('projectId' => $projectId, 'jobId' => $jobId);
  307. $params = array_merge($params, $optParams);
  308. $data = $this->__call('get', array($params));
  309. if ($this->useObjects()) {
  310. return new Job($data);
  311. } else {
  312. return $data;
  313. }
  314. }
  315. /**
  316. * Lists all the Jobs in the specified project that were started by the user. (jobs.list)
  317. *
  318. * @param string $projectId Project ID of the jobs to list
  319. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  320. *
  321. * @opt_param string projection Restrict information returned to a set of selected fields
  322. * @opt_param string stateFilter Filter for job state
  323. * @opt_param bool allUsers Whether to display jobs owned by all users in the project. Default false
  324. * @opt_param string maxResults Maximum number of results to return
  325. * @opt_param string pageToken Page token, returned by a previous call, to request the next page of results
  326. * @return JobList
  327. */
  328. public function listJobs($projectId, $optParams = array()) {
  329. $params = array('projectId' => $projectId);
  330. $params = array_merge($params, $optParams);
  331. $data = $this->__call('list', array($params));
  332. if ($this->useObjects()) {
  333. return new JobList($data);
  334. } else {
  335. return $data;
  336. }
  337. }
  338. /**
  339. * Runs a BigQuery SQL query synchronously and returns query results if the query completes within a
  340. * specified timeout. (jobs.query)
  341. *
  342. * @param string $projectId Project ID of the project billed for the query
  343. * @param QueryRequest $postBody
  344. * @return QueryResponse
  345. */
  346. public function query($projectId, QueryRequest $postBody, $optParams = array()) {
  347. $params = array('projectId' => $projectId, 'postBody' => $postBody);
  348. $params = array_merge($params, $optParams);
  349. $data = $this->__call('query', array($params));
  350. if ($this->useObjects()) {
  351. return new QueryResponse($data);
  352. } else {
  353. return $data;
  354. }
  355. }
  356. /**
  357. * Retrieves the results of a query job. (jobs.getQueryResults)
  358. *
  359. * @param string $projectId Project ID of the query job
  360. * @param string $jobId Job ID of the query job
  361. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  362. *
  363. * @opt_param string timeoutMs How long to wait for the query to complete, in milliseconds, before returning. Default is to return immediately. If the timeout passes before the job completes, the request will fail with a TIMEOUT error
  364. * @opt_param string startIndex Zero-based index of the starting row
  365. * @opt_param string maxResults Maximum number of results to read
  366. * @return GetQueryResultsResponse
  367. */
  368. public function getQueryResults($projectId, $jobId, $optParams = array()) {
  369. $params = array('projectId' => $projectId, 'jobId' => $jobId);
  370. $params = array_merge($params, $optParams);
  371. $data = $this->__call('getQueryResults', array($params));
  372. if ($this->useObjects()) {
  373. return new GetQueryResultsResponse($data);
  374. } else {
  375. return $data;
  376. }
  377. }
  378. /**
  379. * Deletes a completed job specified by job ID. (jobs.delete)
  380. *
  381. * @param string $projectId Project ID of the job to delete
  382. * @param string $jobId Job ID of the job to delete
  383. */
  384. public function delete($projectId, $jobId, $optParams = array()) {
  385. $params = array('projectId' => $projectId, 'jobId' => $jobId);
  386. $params = array_merge($params, $optParams);
  387. $data = $this->__call('delete', array($params));
  388. return $data;
  389. }
  390. }
  391. /**
  392. * The "tabledata" collection of methods.
  393. * Typical usage is:
  394. * <code>
  395. * $bigqueryService = new apiBigqueryService(...);
  396. * $tabledata = $bigqueryService->tabledata;
  397. * </code>
  398. */
  399. class TabledataServiceResource extends apiServiceResource {
  400. /**
  401. * Retrieves table data from a specified set of rows. (tabledata.list)
  402. *
  403. * @param string $projectId Project ID of the table to read
  404. * @param string $datasetId Dataset ID of the table to read
  405. * @param string $tableId Table ID of the table to read
  406. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  407. *
  408. * @opt_param string startIndex Zero-based index of the starting row to read
  409. * @opt_param string maxResults Maximum number of results to return
  410. * @return TableDataList
  411. */
  412. public function listTabledata($projectId, $datasetId, $tableId, $optParams = array()) {
  413. $params = array('projectId' => $projectId, 'datasetId' => $datasetId, 'tableId' => $tableId);
  414. $params = array_merge($params, $optParams);
  415. $data = $this->__call('list', array($params));
  416. if ($this->useObjects()) {
  417. return new TableDataList($data);
  418. } else {
  419. return $data;
  420. }
  421. }
  422. }
  423. /**
  424. * The "projects" collection of methods.
  425. * Typical usage is:
  426. * <code>
  427. * $bigqueryService = new apiBigqueryService(...);
  428. * $projects = $bigqueryService->projects;
  429. * </code>
  430. */
  431. class ProjectsServiceResource extends apiServiceResource {
  432. /**
  433. * Lists the projects to which you have at least read access. (projects.list)
  434. *
  435. * @param array $optParams Optional parameters. Valid optional parameters are listed below.
  436. *
  437. * @opt_param string pageToken Page token, returned by a previous call, to request the next page of results
  438. * @opt_param string maxResults Maximum number of results to return
  439. * @return ProjectList
  440. */
  441. public function listProjects($optParams = array()) {
  442. $params = array();
  443. $params = array_merge($params, $optParams);
  444. $data = $this->__call('list', array($params));
  445. if ($this->useObjects()) {
  446. return new ProjectList($data);
  447. } else {
  448. return $data;
  449. }
  450. }
  451. }
  452. /**
  453. * Service definition for Bigquery (v2).
  454. *
  455. * <p>
  456. * A data platform for customers to create, manage, share and query data.
  457. * </p>
  458. *
  459. * <p>
  460. * For more information about this service, see the
  461. * <a href="https://code.google.com/apis/bigquery/docs/v2/" target="_blank">API Documentation</a>
  462. * </p>
  463. *
  464. * @author Google, Inc.
  465. */
  466. class apiBigqueryService extends apiService {
  467. public $tables;
  468. public $datasets;
  469. public $jobs;
  470. public $tabledata;
  471. public $projects;
  472. /**
  473. * Constructs the internal representation of the Bigquery service.
  474. *
  475. * @param apiClient apiClient
  476. */
  477. public function __construct(apiClient $apiClient) {
  478. $this->rpcPath = '/rpc';
  479. $this->restBasePath = '/bigquery/v2/';
  480. $this->version = 'v2';
  481. $this->serviceName = 'bigquery';
  482. $apiClient->addService($this->serviceName, $this->version);
  483. $this->tables = new TablesServiceResource($this, $this->serviceName, 'tables', json_decode('{"methods": {"insert": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"type": "string", "location": "path"}, "datasetId": {"type": "string", "location": "path"}}, "request": {"$ref": "Table"}, "id": "bigquery.tables.insert", "httpMethod": "POST", "path": "projects/{projectId}/datasets/{datasetId}/tables", "response": {"$ref": "Table"}}, "get": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "tableId": {"required": true, "type": "string", "location": "path"}, "datasetId": {"required": true, "type": "string", "location": "path"}}, "id": "bigquery.tables.get", "httpMethod": "GET", "path": "projects/{projectId}/datasets/{datasetId}/tables/{tableId}", "response": {"$ref": "Table"}}, "list": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"pageToken": {"type": "string", "location": "query"}, "datasetId": {"required": true, "type": "string", "location": "path"}, "maxResults": {"format": "uint32", "type": "integer", "location": "query"}, "projectId": {"required": true, "type": "string", "location": "path"}}, "id": "bigquery.tables.list", "httpMethod": "GET", "path": "projects/{projectId}/datasets/{datasetId}/tables", "response": {"$ref": "TableList"}}, "update": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"type": "string", "location": "path"}, "tableId": {"type": "string", "location": "path"}, "datasetId": {"type": "string", "location": "path"}}, "request": {"$ref": "Table"}, "id": "bigquery.tables.update", "httpMethod": "PUT", "path": "projects/{projectId}/datasets/{datasetId}/tables/{tableId}", "response": {"$ref": "Table"}}, "patch": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "tableId": {"required": true, "type": "string", "location": "path"}, "datasetId": {"required": true, "type": "string", "location": "path"}}, "request": {"$ref": "Table"}, "id": "bigquery.tables.patch", "httpMethod": "PATCH", "path": "projects/{projectId}/datasets/{datasetId}/tables/{tableId}", "response": {"$ref": "Table"}}, "delete": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "tableId": {"required": true, "type": "string", "location": "path"}, "datasetId": {"required": true, "type": "string", "location": "path"}}, "httpMethod": "DELETE", "path": "projects/{projectId}/datasets/{datasetId}/tables/{tableId}", "id": "bigquery.tables.delete"}}}', true));
  484. $this->datasets = new DatasetsServiceResource($this, $this->serviceName, 'datasets', json_decode('{"methods": {"insert": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"type": "string", "location": "path"}}, "request": {"$ref": "Dataset"}, "id": "bigquery.datasets.insert", "httpMethod": "POST", "path": "projects/{projectId}/datasets", "response": {"$ref": "Dataset"}}, "get": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "datasetId": {"required": true, "type": "string", "location": "path"}}, "id": "bigquery.datasets.get", "httpMethod": "GET", "path": "projects/{projectId}/datasets/{datasetId}", "response": {"$ref": "Dataset"}}, "list": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"pageToken": {"type": "string", "location": "query"}, "maxResults": {"format": "uint32", "type": "integer", "location": "query"}, "projectId": {"required": true, "type": "string", "location": "path"}}, "id": "bigquery.datasets.list", "httpMethod": "GET", "path": "projects/{projectId}/datasets", "response": {"$ref": "DatasetList"}}, "update": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"type": "string", "location": "path"}, "datasetId": {"type": "string", "location": "path"}}, "request": {"$ref": "Dataset"}, "id": "bigquery.datasets.update", "httpMethod": "PUT", "path": "projects/{projectId}/datasets/{datasetId}", "response": {"$ref": "Dataset"}}, "patch": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "datasetId": {"required": true, "type": "string", "location": "path"}}, "request": {"$ref": "Dataset"}, "id": "bigquery.datasets.patch", "httpMethod": "PATCH", "path": "projects/{projectId}/datasets/{datasetId}", "response": {"$ref": "Dataset"}}, "delete": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"deleteContents": {"type": "boolean", "location": "query"}, "datasetId": {"required": true, "type": "string", "location": "path"}, "projectId": {"required": true, "type": "string", "location": "path"}}, "httpMethod": "DELETE", "path": "projects/{projectId}/datasets/{datasetId}", "id": "bigquery.datasets.delete"}}}', true));
  485. $this->jobs = new JobsServiceResource($this, $this->serviceName, 'jobs', json_decode('{"methods": {"insert": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"type": "string", "location": "path"}}, "mediaUpload": {"accept": ["application/octet-stream"], "protocols": {"simple": {"path": "/upload/bigquery/v2/projects/{projectId}/jobs", "multipart": true}, "resumable": {"path": "/resumable/upload/bigquery/v2/projects/{projectId}/jobs", "multipart": true}}}, "request": {"$ref": "Job"}, "id": "bigquery.jobs.insert", "httpMethod": "POST", "path": "projects/{projectId}/jobs", "response": {"$ref": "Job"}}, "get": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "jobId": {"required": true, "type": "string", "location": "path"}}, "id": "bigquery.jobs.get", "httpMethod": "GET", "path": "projects/{projectId}/jobs/{jobId}", "response": {"$ref": "Job"}}, "list": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projection": {"enum": ["full", "minimal"], "type": "string", "location": "query"}, "stateFilter": {"enum": ["done", "pending", "running"], "repeated": true, "location": "query", "type": "string"}, "projectId": {"required": true, "type": "string", "location": "path"}, "allUsers": {"type": "boolean", "location": "query"}, "maxResults": {"format": "uint32", "type": "integer", "location": "query"}, "pageToken": {"type": "string", "location": "query"}}, "id": "bigquery.jobs.list", "httpMethod": "GET", "path": "projects/{projectId}/jobs", "response": {"$ref": "JobList"}}, "query": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}}, "request": {"$ref": "QueryRequest"}, "id": "bigquery.jobs.query", "httpMethod": "POST", "path": "projects/{projectId}/queries", "response": {"$ref": "QueryResponse"}}, "getQueryResults": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"timeoutMs": {"format": "uint32", "type": "integer", "location": "query"}, "projectId": {"required": true, "type": "string", "location": "path"}, "startIndex": {"format": "uint64", "type": "string", "location": "query"}, "maxResults": {"format": "uint32", "type": "integer", "location": "query"}, "jobId": {"required": true, "type": "string", "location": "path"}}, "id": "bigquery.jobs.getQueryResults", "httpMethod": "GET", "path": "projects/{projectId}/queries/{jobId}", "response": {"$ref": "GetQueryResultsResponse"}}, "delete": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "jobId": {"required": true, "type": "string", "location": "path"}}, "httpMethod": "DELETE", "path": "projects/{projectId}/jobs/{jobId}", "id": "bigquery.jobs.delete"}}}', true));
  486. $this->tabledata = new TabledataServiceResource($this, $this->serviceName, 'tabledata', json_decode('{"methods": {"list": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"projectId": {"required": true, "type": "string", "location": "path"}, "startIndex": {"format": "uint64", "type": "string", "location": "query"}, "tableId": {"required": true, "type": "string", "location": "path"}, "datasetId": {"required": true, "type": "string", "location": "path"}, "maxResults": {"format": "uint32", "type": "integer", "location": "query"}}, "id": "bigquery.tabledata.list", "httpMethod": "GET", "path": "projects/{projectId}/datasets/{datasetId}/tables/{tableId}/data", "response": {"$ref": "TableDataList"}}}}', true));
  487. $this->projects = new ProjectsServiceResource($this, $this->serviceName, 'projects', json_decode('{"methods": {"list": {"scopes": ["https://www.googleapis.com/auth/bigquery"], "parameters": {"pageToken": {"type": "string", "location": "query"}, "maxResults": {"format": "uint32", "type": "integer", "location": "query"}}, "response": {"$ref": "ProjectList"}, "httpMethod": "GET", "path": "projects", "id": "bigquery.projects.list"}}}', true));
  488. }
  489. }
  490. class Dataset extends apiModel {
  491. public $kind;
  492. public $description;
  493. protected $__datasetReferenceType = 'DatasetReference';
  494. protected $__datasetReferenceDataType = '';
  495. public $datasetReference;
  496. public $creationTime;
  497. protected $__accessType = 'DatasetAccess';
  498. protected $__accessDataType = 'array';
  499. public $access;
  500. public $etag;
  501. public $friendlyName;
  502. public $lastModifiedTime;
  503. public $id;
  504. public $selfLink;
  505. public function setKind($kind) {
  506. $this->kind = $kind;
  507. }
  508. public function getKind() {
  509. return $this->kind;
  510. }
  511. public function setDescription($description) {
  512. $this->description = $description;
  513. }
  514. public function getDescription() {
  515. return $this->description;
  516. }
  517. public function setDatasetReference(DatasetReference $datasetReference) {
  518. $this->datasetReference = $datasetReference;
  519. }
  520. public function getDatasetReference() {
  521. return $this->datasetReference;
  522. }
  523. public function setCreationTime($creationTime) {
  524. $this->creationTime = $creationTime;
  525. }
  526. public function getCreationTime() {
  527. return $this->creationTime;
  528. }
  529. public function setAccess(/* array(DatasetAccess) */ $access) {
  530. $this->assertIsArray($access, 'DatasetAccess', __METHOD__);
  531. $this->access = $access;
  532. }
  533. public function getAccess() {
  534. return $this->access;
  535. }
  536. public function setEtag($etag) {
  537. $this->etag = $etag;
  538. }
  539. public function getEtag() {
  540. return $this->etag;
  541. }
  542. public function setFriendlyName($friendlyName) {
  543. $this->friendlyName = $friendlyName;
  544. }
  545. public function getFriendlyName() {
  546. return $this->friendlyName;
  547. }
  548. public function setLastModifiedTime($lastModifiedTime) {
  549. $this->lastModifiedTime = $lastModifiedTime;
  550. }
  551. public function getLastModifiedTime() {
  552. return $this->lastModifiedTime;
  553. }
  554. public function setId($id) {
  555. $this->id = $id;
  556. }
  557. public function getId() {
  558. return $this->id;
  559. }
  560. public function setSelfLink($selfLink) {
  561. $this->selfLink = $selfLink;
  562. }
  563. public function getSelfLink() {
  564. return $this->selfLink;
  565. }
  566. }
  567. class DatasetAccess extends apiModel {
  568. public $specialGroup;
  569. public $domain;
  570. public $role;
  571. public $groupByEmail;
  572. public $userByEmail;
  573. public function setSpecialGroup($specialGroup) {
  574. $this->specialGroup = $specialGroup;
  575. }
  576. public function getSpecialGroup() {
  577. return $this->specialGroup;
  578. }
  579. public function setDomain($domain) {
  580. $this->domain = $domain;
  581. }
  582. public function getDomain() {
  583. return $this->domain;
  584. }
  585. public function setRole($role) {
  586. $this->role = $role;
  587. }
  588. public function getRole() {
  589. return $this->role;
  590. }
  591. public function setGroupByEmail($groupByEmail) {
  592. $this->groupByEmail = $groupByEmail;
  593. }
  594. public function getGroupByEmail() {
  595. return $this->groupByEmail;
  596. }
  597. public function setUserByEmail($userByEmail) {
  598. $this->userByEmail = $userByEmail;
  599. }
  600. public function getUserByEmail() {
  601. return $this->userByEmail;
  602. }
  603. }
  604. class DatasetList extends apiModel {
  605. public $nextPageToken;
  606. public $kind;
  607. protected $__datasetsType = 'DatasetListDatasets';
  608. protected $__datasetsDataType = 'array';
  609. public $datasets;
  610. public $etag;
  611. public function setNextPageToken($nextPageToken) {
  612. $this->nextPageToken = $nextPageToken;
  613. }
  614. public function getNextPageToken() {
  615. return $this->nextPageToken;
  616. }
  617. public function setKind($kind) {
  618. $this->kind = $kind;
  619. }
  620. public function getKind() {
  621. return $this->kind;
  622. }
  623. public function setDatasets(/* array(DatasetListDatasets) */ $datasets) {
  624. $this->assertIsArray($datasets, 'DatasetListDatasets', __METHOD__);
  625. $this->datasets = $datasets;
  626. }
  627. public function getDatasets() {
  628. return $this->datasets;
  629. }
  630. public function setEtag($etag) {
  631. $this->etag = $etag;
  632. }
  633. public function getEtag() {
  634. return $this->etag;
  635. }
  636. }
  637. class DatasetListDatasets extends apiModel {
  638. public $friendlyName;
  639. public $kind;
  640. public $id;
  641. protected $__datasetReferenceType = 'DatasetReference';
  642. protected $__datasetReferenceDataType = '';
  643. public $datasetReference;
  644. public function setFriendlyName($friendlyName) {
  645. $this->friendlyName = $friendlyName;
  646. }
  647. public function getFriendlyName() {
  648. return $this->friendlyName;
  649. }
  650. public function setKind($kind) {
  651. $this->kind = $kind;
  652. }
  653. public function getKind() {
  654. return $this->kind;
  655. }
  656. public function setId($id) {
  657. $this->id = $id;
  658. }
  659. public function getId() {
  660. return $this->id;
  661. }
  662. public function setDatasetReference(DatasetReference $datasetReference) {
  663. $this->datasetReference = $datasetReference;
  664. }
  665. public function getDatasetReference() {
  666. return $this->datasetReference;
  667. }
  668. }
  669. class DatasetReference extends apiModel {
  670. public $projectId;
  671. public $datasetId;
  672. public function setProjectId($projectId) {
  673. $this->projectId = $projectId;
  674. }
  675. public function getProjectId() {
  676. return $this->projectId;
  677. }
  678. public function setDatasetId($datasetId) {
  679. $this->datasetId = $datasetId;
  680. }
  681. public function getDatasetId() {
  682. return $this->datasetId;
  683. }
  684. }
  685. class ErrorProto extends apiModel {
  686. public $debugInfo;
  687. public $message;
  688. public $reason;
  689. public $location;
  690. public function setDebugInfo($debugInfo) {
  691. $this->debugInfo = $debugInfo;
  692. }
  693. public function getDebugInfo() {
  694. return $this->debugInfo;
  695. }
  696. public function setMessage($message) {
  697. $this->message = $message;
  698. }
  699. public function getMessage() {
  700. return $this->message;
  701. }
  702. public function setReason($reason) {
  703. $this->reason = $reason;
  704. }
  705. public function getReason() {
  706. return $this->reason;
  707. }
  708. public function setLocation($location) {
  709. $this->location = $location;
  710. }
  711. public function getLocation() {
  712. return $this->location;
  713. }
  714. }
  715. class GetQueryResultsResponse extends apiModel {
  716. public $kind;
  717. protected $__rowsType = 'TableRow';
  718. protected $__rowsDataType = 'array';
  719. public $rows;
  720. protected $__jobReferenceType = 'JobReference';
  721. protected $__jobReferenceDataType = '';
  722. public $jobReference;
  723. public $jobComplete;
  724. public $totalRows;
  725. public $etag;
  726. protected $__schemaType = 'TableSchema';
  727. protected $__schemaDataType = '';
  728. public $schema;
  729. public function setKind($kind) {
  730. $this->kind = $kind;
  731. }
  732. public function getKind() {
  733. return $this->kind;
  734. }
  735. public function setRows(/* array(TableRow) */ $rows) {
  736. $this->assertIsArray($rows, 'TableRow', __METHOD__);
  737. $this->rows = $rows;
  738. }
  739. public function getRows() {
  740. return $this->rows;
  741. }
  742. public function setJobReference(JobReference $jobReference) {
  743. $this->jobReference = $jobReference;
  744. }
  745. public function getJobReference() {
  746. return $this->jobReference;
  747. }
  748. public function setJobComplete($jobComplete) {
  749. $this->jobComplete = $jobComplete;
  750. }
  751. public function getJobComplete() {
  752. return $this->jobComplete;
  753. }
  754. public function setTotalRows($totalRows) {
  755. $this->totalRows = $totalRows;
  756. }
  757. public function getTotalRows() {
  758. return $this->totalRows;
  759. }
  760. public function setEtag($etag) {
  761. $this->etag = $etag;
  762. }
  763. public function getEtag() {
  764. return $this->etag;
  765. }
  766. public function setSchema(TableSchema $schema) {
  767. $this->schema = $schema;
  768. }
  769. public function getSchema() {
  770. return $this->schema;
  771. }
  772. }
  773. class Job extends apiModel {
  774. protected $__statusType = 'JobStatus';
  775. protected $__statusDataType = '';
  776. public $status;
  777. public $kind;
  778. protected $__statisticsType = 'JobStatistics';
  779. protected $__statisticsDataType = '';
  780. public $statistics;
  781. protected $__jobReferenceType = 'JobReference';
  782. protected $__jobReferenceDataType = '';
  783. public $jobReference;
  784. public $etag;
  785. protected $__configurationType = 'JobConfiguration';
  786. protected $__configurationDataType = '';
  787. public $configuration;
  788. public $id;
  789. public $selfLink;
  790. public function setStatus(JobStatus $status) {
  791. $this->status = $status;
  792. }
  793. public function getStatus() {
  794. return $this->status;
  795. }
  796. public function setKind($kind) {
  797. $this->kind = $kind;
  798. }
  799. public function getKind() {
  800. return $this->kind;
  801. }
  802. public function setStatistics(JobStatistics $statistics) {
  803. $this->statistics = $statistics;
  804. }
  805. public function getStatistics() {
  806. return $this->statistics;
  807. }
  808. public function setJobReference(JobReference $jobReference) {
  809. $this->jobReference = $jobReference;
  810. }
  811. public function getJobReference() {
  812. return $this->jobReference;
  813. }
  814. public function setEtag($etag) {
  815. $this->etag = $etag;
  816. }
  817. public function getEtag() {
  818. return $this->etag;
  819. }
  820. public function setConfiguration(JobConfiguration $configuration) {
  821. $this->configuration = $configuration;
  822. }
  823. public function getConfiguration() {
  824. return $this->configuration;
  825. }
  826. public function setId($id) {
  827. $this->id = $id;
  828. }
  829. public function getId() {
  830. return $this->id;
  831. }
  832. public function setSelfLink($selfLink) {
  833. $this->selfLink = $selfLink;
  834. }
  835. public function getSelfLink() {
  836. return $this->selfLink;
  837. }
  838. }
  839. class JobConfiguration extends apiModel {
  840. protected $__loadType = 'JobConfigurationLoad';
  841. protected $__loadDataType = '';
  842. public $load;
  843. protected $__linkType = 'JobConfigurationLink';
  844. protected $__linkDataType = '';
  845. public $link;
  846. protected $__queryType = 'JobConfigurationQuery';
  847. protected $__queryDataType = '';
  848. public $query;
  849. protected $__copyType = 'JobConfigurationTableCopy';
  850. protected $__copyDataType = '';
  851. public $copy;
  852. protected $__extractType = 'JobConfigurationExtract';
  853. protected $__extractDataType = '';
  854. public $extract;
  855. public $properties;
  856. public function setLoad(JobConfigurationLoad $load) {
  857. $this->load = $load;
  858. }
  859. public function getLoad() {
  860. return $this->load;
  861. }
  862. public function setLink(JobConfigurationLink $link) {
  863. $this->link = $link;
  864. }
  865. public function getLink() {
  866. return $this->link;
  867. }
  868. public function setQuery(JobConfigurationQuery $query) {
  869. $this->query = $query;
  870. }
  871. public function getQuery() {
  872. return $this->query;
  873. }
  874. public function setCopy(JobConfigurationTableCopy $copy) {
  875. $this->copy = $copy;
  876. }
  877. public function getCopy() {
  878. return $this->copy;
  879. }
  880. public function setExtract(JobConfigurationExtract $extract) {
  881. $this->extract = $extract;
  882. }
  883. public function getExtract() {
  884. return $this->extract;
  885. }
  886. public function setProperties($properties) {
  887. $this->properties = $properties;
  888. }
  889. public function getProperties() {
  890. return $this->properties;
  891. }
  892. }
  893. class JobConfigurationExtract extends apiModel {
  894. public $destinationUri;
  895. protected $__sourceTableType = 'TableReference';
  896. protected $__sourceTableDataType = '';
  897. public $sourceTable;
  898. public function setDestinationUri($destinationUri) {
  899. $this->destinationUri = $destinationUri;
  900. }
  901. public function getDestinationUri() {
  902. return $this->destinationUri;
  903. }
  904. public function setSourceTable(TableReference $sourceTable) {
  905. $this->sourceTable = $sourceTable;
  906. }
  907. public function getSourceTable() {
  908. return $this->sourceTable;
  909. }
  910. }
  911. class JobConfigurationLink extends apiModel {
  912. public $createDisposition;
  913. protected $__destinationTableType = 'TableReference';
  914. protected $__destinationTableDataType = '';
  915. public $destinationTable;
  916. public $sourceUri;
  917. public function setCreateDisposition($createDisposition) {
  918. $this->createDisposition = $createDisposition;
  919. }
  920. public function getCreateDisposition() {
  921. return $this->createDisposition;
  922. }
  923. public function setDestinationTable(TableReference $destinationTable) {
  924. $this->destinationTable = $destinationTable;
  925. }
  926. public function getDestinationTable() {
  927. return $this->destinationTable;
  928. }
  929. public function setSourceUri($sourceUri) {
  930. $this->sourceUri = $sourceUri;
  931. }
  932. public function getSourceUri() {
  933. return $this->sourceUri;
  934. }
  935. }
  936. class JobConfigurationLoad extends apiModel {
  937. public $encoding;
  938. public $fieldDelimiter;
  939. protected $__destinationTableType = 'TableReference';
  940. protected $__destinationTableDataType = '';
  941. public $destinationTable;
  942. public $maxBadRecords;
  943. public $writeDisposition;
  944. public $sourceUris;
  945. public $skipLeadingRows;
  946. public $createDisposition;
  947. protected $__schemaType = 'TableSchema';
  948. protected $__schemaDataType = '';
  949. public $schema;
  950. public function setEncoding($encoding) {
  951. $this->encoding = $encoding;
  952. }
  953. public function getEncoding() {
  954. return $this->encoding;
  955. }
  956. public function setFieldDelimiter($fieldDelimiter) {
  957. $this->fieldDelimiter = $fieldDelimiter;
  958. }
  959. public function getFieldDelimiter() {
  960. return $this->fieldDelimiter;
  961. }
  962. public function setDestinationTable(TableReference $destinationTable) {
  963. $this->destinationTable = $destinationTable;
  964. }
  965. public function getDestinationTable() {
  966. return $this->destinationTable;
  967. }
  968. public function setMaxBadRecords($maxBadRecords) {
  969. $this->maxBadRecords = $maxBadRecords;
  970. }
  971. public function getMaxBadRecords() {
  972. return $this->maxBadRecords;
  973. }
  974. public function setWriteDisposition($writeDisposition) {
  975. $this->writeDisposition = $writeDisposition;
  976. }
  977. public function getWriteDisposition() {
  978. return $this->writeDisposition;
  979. }
  980. public function setSourceUris(/* array(string) */ $sourceUris) {
  981. $this->assertIsArray($sourceUris, 'string', __METHOD__);
  982. $this->sourceUris = $sourceUris;
  983. }
  984. public function getSourceUris() {
  985. return $this->sourceUris;
  986. }
  987. public function setSkipLeadingRows($skipLeadingRows) {
  988. $this->skipLeadingRows = $skipLeadingRows;
  989. }
  990. public function getSkipLeadingRows() {
  991. return $this->skipLeadingRows;
  992. }
  993. public function setCreateDisposition($createDisposition) {
  994. $this->createDisposition = $createDisposition;
  995. }
  996. public function getCreateDisposition() {
  997. return $this->createDisposition;
  998. }
  999. public function setSchema(TableSchema $schema) {
  1000. $this->schema = $schema;
  1001. }
  1002. public function getSchema() {
  1003. return $this->schema;
  1004. }
  1005. }
  1006. class JobConfigurationQuery extends apiModel {
  1007. public $createDisposition;
  1008. public $query;
  1009. public $writeDisposition;
  1010. protected $__destinationTableType = 'TableReference';
  1011. protected $__destinationTableDataType = '';
  1012. public $destinationTable;
  1013. protected $__defaultDatasetType = 'DatasetReference';
  1014. protected $__defaultDatasetDataType = '';
  1015. public $defaultDataset;
  1016. public function setCreateDisposition($createDisposition) {
  1017. $this->createDisposition = $createDisposition;
  1018. }
  1019. public function getCreateDisposition() {
  1020. return $this->createDisposition;
  1021. }
  1022. public function setQuery($query) {
  1023. $this->query = $query;
  1024. }
  1025. public function getQuery() {
  1026. return $this->query;
  1027. }
  1028. public function setWriteDisposition($writeDisposition) {
  1029. $this->writeDisposition = $writeDisposition;
  1030. }
  1031. public function getWriteDisposition() {
  1032. return $this->writeDisposition;
  1033. }
  1034. public function setDestinationTable(TableReference $destinationTable) {
  1035. $this->destinationTable = $destinationTable;
  1036. }
  1037. public function getDestinationTable() {
  1038. return $this->destinationTable;
  1039. }
  1040. public function setDefaultDataset(DatasetReference $defaultDataset) {
  1041. $this->defaultDataset = $defaultDataset;
  1042. }
  1043. public function getDefaultDataset() {
  1044. return $this->defaultDataset;
  1045. }
  1046. }
  1047. class JobConfigurationTableCopy extends apiModel {
  1048. public $createDisposition;
  1049. public $writeDisposition;
  1050. protected $__destinationTableType = 'TableReference';
  1051. protected $__destinationTableDataType = '';
  1052. public $destinationTable;
  1053. protected $__sourceTableType = 'TableReference';
  1054. protected $__sourceTableDataType = '';
  1055. public $sourceTable;
  1056. public function setCreateDisposition($createDisposition) {
  1057. $this->createDisposition = $createDisposition;
  1058. }
  1059. public function getCreateDisposition() {
  1060. return $this->createDisposition;
  1061. }
  1062. public function setWriteDisposition($writeDisposition) {
  1063. $this->writeDisposition = $writeDisposition;
  1064. }
  1065. public function getWriteDisposition() {
  1066. return $this->writeDisposition;
  1067. }
  1068. public function setDestinationTable(TableReference $destinationTable) {
  1069. $this->destinationTable = $destinationTable;
  1070. }
  1071. public function getDestinationTable() {
  1072. return $this->destinationTable;
  1073. }
  1074. public function setSourceTable(TableReference $sourceTable) {
  1075. $this->sourceTable = $sourceTable;
  1076. }
  1077. public function getSourceTable() {
  1078. return $this->sourceTable;
  1079. }
  1080. }
  1081. class JobList extends apiModel {
  1082. public $nextPageToken;
  1083. public $totalItems;
  1084. public $kind;
  1085. public $etag;
  1086. protected $__jobsType = 'JobListJobs';
  1087. protected $__jobsDataType = 'array';
  1088. public $jobs;
  1089. public function setNextPageToken($nextPageToken) {
  1090. $this->nextPageToken = $nextPageToken;
  1091. }
  1092. public function getNextPageToken() {
  1093. return $this->nextPageToken;
  1094. }
  1095. public function setTotalItems($totalItems) {
  1096. $this->totalItems = $totalItems;
  1097. }
  1098. public function getTotalItems() {
  1099. return $this->totalItems;
  1100. }
  1101. public function setKind($kind) {
  1102. $this->kind = $kind;
  1103. }
  1104. public function getKind() {
  1105. return $this->kind;
  1106. }
  1107. public function setEtag($etag) {
  1108. $this->etag = $etag;
  1109. }
  1110. public function getEtag() {
  1111. return $this->etag;
  1112. }
  1113. public function setJobs(/* array(JobListJobs) */ $jobs) {
  1114. $this->assertIsArray($jobs, 'JobListJobs', __METHOD__);
  1115. $this->jobs = $jobs;
  1116. }
  1117. public function getJobs() {
  1118. return $this->jobs;
  1119. }
  1120. }
  1121. class JobListJobs extends apiModel {
  1122. protected $__statusType = 'JobStatus';
  1123. protected $__statusDataType = '';
  1124. public $status;
  1125. protected $__statisticsType = 'JobStatistics';
  1126. protected $__statisticsDataType = '';
  1127. public $statistics;
  1128. protected $__jobReferenceType = 'JobReference';
  1129. protected $__jobReferenceDataType = '';
  1130. public $jobReference;
  1131. public $state;
  1132. protected $__configurationType = 'JobConfiguration';
  1133. protected $__configurationDataType = '';
  1134. public $configuration;
  1135. public $id;
  1136. protected $__errorResultType = 'ErrorProto';
  1137. protected $__errorResultDataType = '';
  1138. public $errorResult;
  1139. public function setStatus(JobStatus $status) {
  1140. $this->status = $status;
  1141. }
  1142. public function getStatus() {
  1143. return $this->status;
  1144. }
  1145. public function setStatistics(JobStatistics $statistics) {
  1146. $this->statistics = $statistics;
  1147. }
  1148. public function getStatistics() {
  1149. return $this->statistics;
  1150. }
  1151. public function setJobReference(JobReference $jobReference) {
  1152. $this->jobReference = $jobReference;
  1153. }
  1154. public function getJobReference() {
  1155. return $this->jobReference;
  1156. }
  1157. public function setState($state) {
  1158. $this->state = $state;
  1159. }
  1160. public function getState() {
  1161. return $this->state;
  1162. }
  1163. public function setConfiguration(JobConfiguration $configuration) {
  1164. $this->configuration = $configuration;
  1165. }
  1166. public function getConfiguration() {
  1167. return $this->configuration;
  1168. }
  1169. public function setId($id) {
  1170. $this->id = $id;
  1171. }
  1172. public function getId() {
  1173. return $this->id;
  1174. }
  1175. public function setErrorResult(ErrorProto $errorResult) {
  1176. $this->errorResult = $errorResult;
  1177. }
  1178. public function getErrorResult() {
  1179. return $this->errorResult;
  1180. }
  1181. }
  1182. class JobReference extends apiModel {
  1183. public $projectId;
  1184. public $jobId;
  1185. public function setProjectId($projectId) {
  1186. $this->projectId = $projectId;
  1187. }
  1188. public function getProjectId() {
  1189. return $this->projectId;
  1190. }
  1191. public function setJobId($jobId) {
  1192. $this->jobId = $jobId;
  1193. }
  1194. public function getJobId() {
  1195. return $this->jobId;
  1196. }
  1197. }
  1198. class JobStatistics extends apiModel {
  1199. public $endTime;
  1200. public $totalBytesProcessed;
  1201. public $startTime;
  1202. public function setEndTime($endTime) {
  1203. $this->endTime = $endTime;
  1204. }
  1205. public function getEndTime() {
  1206. return $this->endTime;
  1207. }
  1208. public function setTotalBytesProcessed($totalBytesProcessed) {
  1209. $this->totalBytesProcessed = $totalBytesProcessed;
  1210. }
  1211. public function getTotalBytesProcessed() {
  1212. return $this->totalBytesProcessed;
  1213. }
  1214. public function setStartTime($startTime) {
  1215. $this->startTime = $startTime;
  1216. }
  1217. public function getStartTime() {
  1218. return $this->startTime;
  1219. }
  1220. }
  1221. class JobStatus extends apiModel {
  1222. public $state;
  1223. protected $__errorsType = 'ErrorProto';
  1224. protected $__errorsDataType = 'array';
  1225. public $errors;
  1226. protected $__errorResultType = 'ErrorProto';
  1227. protected $__errorResultDataType = '';
  1228. public $errorResult;
  1229. public function setState($state) {
  1230. $this->state = $state;
  1231. }
  1232. public function getState() {
  1233. return $this->state;
  1234. }
  1235. public function setErrors(/* array(ErrorProto) */ $errors) {
  1236. $this->assertIsArray($errors, 'ErrorProto', __METHOD__);
  1237. $this->errors = $errors;
  1238. }
  1239. public function getErrors() {
  1240. return $this->errors;
  1241. }
  1242. public function setErrorResult(ErrorProto $errorResult) {
  1243. $this->errorResult = $errorResult;
  1244. }
  1245. public function getErrorResult() {
  1246. return $this->errorResult;
  1247. }
  1248. }
  1249. class ProjectList extends apiModel {
  1250. public $nextPageToken;
  1251. public $totalItems;
  1252. public $kind;
  1253. public $etag;
  1254. protected $__projectsType = 'ProjectListProjects';
  1255. protected $__projectsDataType = 'array';
  1256. public $projects;
  1257. public function setNextPageToken($nextPageToken) {
  1258. $this->nextPageToken = $nextPageToken;
  1259. }
  1260. public function getNextPageToken() {
  1261. return $this->nextPageToken;
  1262. }
  1263. public function setTotalItems($totalItems) {
  1264. $this->totalItems = $totalItems;
  1265. }
  1266. public function getTotalItems() {
  1267. return $this->totalItems;
  1268. }
  1269. public function setKind($kind) {
  1270. $this->kind = $kind;
  1271. }
  1272. public function getKind() {
  1273. return $th

Large files files are truncated, but you can click here to view the full file