google-api-client 0.8.6 → 0.9.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (537) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +20 -0
  3. data/.rspec +2 -0
  4. data/.rubocop.yml +7 -0
  5. data/.rubocop_todo.yml +63 -0
  6. data/.travis.yml +23 -0
  7. data/.yardopts +12 -0
  8. data/CHANGELOG.md +58 -2
  9. data/CONTRIBUTING.md +31 -0
  10. data/Gemfile +38 -2
  11. data/MIGRATING.md +171 -0
  12. data/README.md +189 -147
  13. data/Rakefile +1 -40
  14. data/api_names.yaml +1088 -0
  15. data/api_names_out.yaml +26978 -0
  16. data/bin/generate-api +109 -0
  17. data/generated/google/apis/adexchangebuyer_v1_3/classes.rb +1335 -0
  18. data/generated/google/apis/adexchangebuyer_v1_3/representations.rb +446 -0
  19. data/generated/google/apis/adexchangebuyer_v1_3/service.rb +872 -0
  20. data/generated/google/apis/adexchangebuyer_v1_3.rb +35 -0
  21. data/generated/google/apis/adexchangebuyer_v1_4/classes.rb +3025 -0
  22. data/generated/google/apis/adexchangebuyer_v1_4/representations.rb +1240 -0
  23. data/generated/google/apis/adexchangebuyer_v1_4/service.rb +1446 -0
  24. data/generated/google/apis/adexchangebuyer_v1_4.rb +35 -0
  25. data/generated/google/apis/adexchangeseller_v2_0/classes.rb +792 -0
  26. data/generated/google/apis/adexchangeseller_v2_0/representations.rb +347 -0
  27. data/generated/google/apis/adexchangeseller_v2_0/service.rb +668 -0
  28. data/generated/google/apis/adexchangeseller_v2_0.rb +38 -0
  29. data/generated/google/apis/admin_datatransfer_v1/classes.rb +267 -0
  30. data/generated/google/apis/admin_datatransfer_v1/representations.rb +130 -0
  31. data/generated/google/apis/admin_datatransfer_v1/service.rb +262 -0
  32. data/generated/google/apis/admin_datatransfer_v1.rb +37 -0
  33. data/generated/google/apis/admin_directory_v1/classes.rb +3141 -0
  34. data/generated/google/apis/admin_directory_v1/representations.rb +1147 -0
  35. data/generated/google/apis/admin_directory_v1/service.rb +3818 -0
  36. data/generated/google/apis/admin_directory_v1.rb +113 -0
  37. data/generated/google/apis/admin_reports_v1/classes.rb +582 -0
  38. data/generated/google/apis/admin_reports_v1/representations.rb +257 -0
  39. data/generated/google/apis/admin_reports_v1/service.rb +336 -0
  40. data/generated/google/apis/admin_reports_v1.rb +38 -0
  41. data/generated/google/apis/adsense_v1_4/classes.rb +1280 -0
  42. data/generated/google/apis/adsense_v1_4/representations.rb +555 -0
  43. data/generated/google/apis/adsense_v1_4/service.rb +1714 -0
  44. data/generated/google/apis/adsense_v1_4.rb +38 -0
  45. data/generated/google/apis/adsensehost_v4_1/classes.rb +837 -0
  46. data/generated/google/apis/adsensehost_v4_1/representations.rb +367 -0
  47. data/generated/google/apis/adsensehost_v4_1/service.rb +1164 -0
  48. data/generated/google/apis/adsensehost_v4_1.rb +35 -0
  49. data/generated/google/apis/analytics_v3/classes.rb +5118 -0
  50. data/generated/google/apis/analytics_v3/representations.rb +1850 -0
  51. data/generated/google/apis/analytics_v3/service.rb +3568 -0
  52. data/generated/google/apis/analytics_v3.rb +49 -0
  53. data/generated/google/apis/androidenterprise_v1/classes.rb +1443 -0
  54. data/generated/google/apis/androidenterprise_v1/representations.rb +614 -0
  55. data/generated/google/apis/androidenterprise_v1/service.rb +2607 -0
  56. data/generated/google/apis/androidenterprise_v1.rb +35 -0
  57. data/generated/google/apis/androidpublisher_v2/classes.rb +1411 -0
  58. data/generated/google/apis/androidpublisher_v2/representations.rb +738 -0
  59. data/generated/google/apis/androidpublisher_v2/service.rb +2338 -0
  60. data/generated/google/apis/androidpublisher_v2.rb +34 -0
  61. data/generated/google/apis/appengine_v1beta4/classes.rb +1585 -0
  62. data/generated/google/apis/appengine_v1beta4/representations.rb +542 -0
  63. data/generated/google/apis/appengine_v1beta4/service.rb +477 -0
  64. data/generated/google/apis/appengine_v1beta4.rb +35 -0
  65. data/generated/google/apis/appengine_v1beta5/classes.rb +1544 -0
  66. data/generated/google/apis/appengine_v1beta5/representations.rb +594 -0
  67. data/generated/google/apis/appengine_v1beta5/service.rb +521 -0
  68. data/generated/google/apis/appengine_v1beta5.rb +35 -0
  69. data/generated/google/apis/appsactivity_v1/classes.rb +392 -0
  70. data/generated/google/apis/appsactivity_v1/representations.rb +206 -0
  71. data/generated/google/apis/appsactivity_v1/service.rb +128 -0
  72. data/generated/google/apis/appsactivity_v1.rb +46 -0
  73. data/generated/google/apis/appstate_v1/classes.rb +154 -0
  74. data/generated/google/apis/appstate_v1/representations.rb +87 -0
  75. data/generated/google/apis/appstate_v1/service.rb +260 -0
  76. data/generated/google/apis/appstate_v1.rb +34 -0
  77. data/generated/google/apis/autoscaler_v1beta2/classes.rb +747 -0
  78. data/generated/google/apis/autoscaler_v1beta2/representations.rb +313 -0
  79. data/generated/google/apis/autoscaler_v1beta2/service.rb +478 -0
  80. data/generated/google/apis/autoscaler_v1beta2.rb +38 -0
  81. data/generated/google/apis/bigquery_v2/classes.rb +2503 -0
  82. data/generated/google/apis/bigquery_v2/representations.rb +914 -0
  83. data/generated/google/apis/bigquery_v2/service.rb +982 -0
  84. data/generated/google/apis/bigquery_v2.rb +52 -0
  85. data/generated/google/apis/blogger_v3/classes.rb +1354 -0
  86. data/generated/google/apis/blogger_v3/representations.rb +632 -0
  87. data/generated/google/apis/blogger_v3/service.rb +1587 -0
  88. data/generated/google/apis/blogger_v3.rb +37 -0
  89. data/generated/google/apis/books_v1/classes.rb +4006 -0
  90. data/generated/google/apis/books_v1/representations.rb +1742 -0
  91. data/generated/google/apis/books_v1/service.rb +2293 -0
  92. data/generated/google/apis/books_v1.rb +34 -0
  93. data/generated/google/apis/calendar_v3/classes.rb +1742 -0
  94. data/generated/google/apis/calendar_v3/representations.rb +631 -0
  95. data/generated/google/apis/calendar_v3/service.rb +1968 -0
  96. data/generated/google/apis/calendar_v3.rb +37 -0
  97. data/generated/google/apis/civicinfo_v2/classes.rb +1127 -0
  98. data/generated/google/apis/civicinfo_v2/representations.rb +423 -0
  99. data/generated/google/apis/civicinfo_v2/service.rb +279 -0
  100. data/generated/google/apis/civicinfo_v2.rb +31 -0
  101. data/generated/google/apis/classroom_v1/classes.rb +512 -0
  102. data/generated/google/apis/classroom_v1/representations.rb +245 -0
  103. data/generated/google/apis/classroom_v1/service.rb +970 -0
  104. data/generated/google/apis/classroom_v1.rb +49 -0
  105. data/generated/google/apis/classroom_v1beta1/classes.rb +447 -0
  106. data/generated/google/apis/classroom_v1beta1/representations.rb +190 -0
  107. data/generated/google/apis/classroom_v1beta1/service.rb +791 -0
  108. data/generated/google/apis/classroom_v1beta1.rb +49 -0
  109. data/generated/google/apis/cloudbilling_v1/classes.rb +169 -0
  110. data/generated/google/apis/cloudbilling_v1/representations.rb +87 -0
  111. data/generated/google/apis/cloudbilling_v1/service.rb +258 -0
  112. data/generated/google/apis/cloudbilling_v1.rb +35 -0
  113. data/generated/google/apis/cloudbuild_v1/classes.rb +521 -0
  114. data/generated/google/apis/cloudbuild_v1/representations.rb +214 -0
  115. data/generated/google/apis/cloudbuild_v1/service.rb +278 -0
  116. data/generated/google/apis/cloudbuild_v1.rb +35 -0
  117. data/generated/google/apis/clouddebugger_v2/classes.rb +1004 -0
  118. data/generated/google/apis/clouddebugger_v2/representations.rb +464 -0
  119. data/generated/google/apis/clouddebugger_v2/service.rb +370 -0
  120. data/generated/google/apis/clouddebugger_v2.rb +41 -0
  121. data/generated/google/apis/cloudlatencytest_v2/classes.rb +195 -0
  122. data/generated/google/apis/cloudlatencytest_v2/representations.rb +127 -0
  123. data/generated/google/apis/cloudlatencytest_v2/service.rb +135 -0
  124. data/generated/google/apis/cloudlatencytest_v2.rb +34 -0
  125. data/generated/google/apis/cloudmonitoring_v2beta2/classes.rb +679 -0
  126. data/generated/google/apis/cloudmonitoring_v2beta2/representations.rb +353 -0
  127. data/generated/google/apis/cloudmonitoring_v2beta2/service.rb +452 -0
  128. data/generated/google/apis/cloudmonitoring_v2beta2.rb +37 -0
  129. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +450 -0
  130. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +226 -0
  131. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +626 -0
  132. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +38 -0
  133. data/generated/google/apis/cloudtrace_v1/classes.rb +188 -0
  134. data/generated/google/apis/cloudtrace_v1/representations.rb +102 -0
  135. data/generated/google/apis/cloudtrace_v1/service.rb +190 -0
  136. data/generated/google/apis/cloudtrace_v1.rb +35 -0
  137. data/generated/google/apis/clouduseraccounts_beta/classes.rb +823 -0
  138. data/generated/google/apis/clouduseraccounts_beta/representations.rb +351 -0
  139. data/generated/google/apis/clouduseraccounts_beta/service.rb +854 -0
  140. data/generated/google/apis/clouduseraccounts_beta.rb +43 -0
  141. data/generated/google/apis/compute_beta/classes.rb +9741 -0
  142. data/generated/google/apis/compute_beta/representations.rb +3649 -0
  143. data/generated/google/apis/compute_beta/service.rb +10636 -0
  144. data/generated/google/apis/compute_beta.rb +49 -0
  145. data/generated/google/apis/compute_v1/classes.rb +9095 -0
  146. data/generated/google/apis/compute_v1/representations.rb +3389 -0
  147. data/generated/google/apis/compute_v1/service.rb +9627 -0
  148. data/generated/google/apis/compute_v1.rb +49 -0
  149. data/generated/google/apis/container_v1/classes.rb +463 -0
  150. data/generated/google/apis/container_v1/representations.rb +195 -0
  151. data/generated/google/apis/container_v1/service.rb +367 -0
  152. data/generated/google/apis/container_v1.rb +35 -0
  153. data/generated/google/apis/container_v1beta1/classes.rb +466 -0
  154. data/generated/google/apis/container_v1beta1/representations.rb +177 -0
  155. data/generated/google/apis/container_v1beta1/service.rb +394 -0
  156. data/generated/google/apis/container_v1beta1.rb +35 -0
  157. data/generated/google/apis/content_v2/classes.rb +6114 -0
  158. data/generated/google/apis/content_v2/representations.rb +2624 -0
  159. data/generated/google/apis/content_v2/service.rb +2338 -0
  160. data/generated/google/apis/content_v2.rb +35 -0
  161. data/generated/google/apis/coordinate_v1/classes.rb +669 -0
  162. data/generated/google/apis/coordinate_v1/representations.rb +321 -0
  163. data/generated/google/apis/coordinate_v1/service.rb +678 -0
  164. data/generated/google/apis/coordinate_v1.rb +37 -0
  165. data/generated/google/apis/customsearch_v1/classes.rb +771 -0
  166. data/generated/google/apis/customsearch_v1/representations.rb +302 -0
  167. data/generated/google/apis/customsearch_v1/service.rb +207 -0
  168. data/{lib/google/api_client/auth/compute_service_account.rb → generated/google/apis/customsearch_v1.rb} +13 -10
  169. data/generated/google/apis/dataproc_v1/classes.rb +1590 -0
  170. data/generated/google/apis/dataproc_v1/representations.rb +653 -0
  171. data/generated/google/apis/dataproc_v1/service.rb +719 -0
  172. data/generated/google/apis/dataproc_v1.rb +43 -0
  173. data/generated/google/apis/datastore_v1beta2/classes.rb +1186 -0
  174. data/generated/google/apis/datastore_v1beta2/representations.rb +594 -0
  175. data/generated/google/apis/datastore_v1beta2/service.rb +294 -0
  176. data/generated/google/apis/datastore_v1beta2.rb +40 -0
  177. data/generated/google/apis/deploymentmanager_v2/classes.rb +1162 -0
  178. data/generated/google/apis/deploymentmanager_v2/representations.rb +508 -0
  179. data/generated/google/apis/deploymentmanager_v2/service.rb +862 -0
  180. data/generated/google/apis/deploymentmanager_v2.rb +44 -0
  181. data/generated/google/apis/deploymentmanager_v2beta2/classes.rb +843 -0
  182. data/generated/google/apis/deploymentmanager_v2beta2/representations.rb +306 -0
  183. data/generated/google/apis/deploymentmanager_v2beta2/service.rb +689 -0
  184. data/generated/google/apis/deploymentmanager_v2beta2.rb +44 -0
  185. data/generated/google/apis/dfareporting_v2_1/classes.rb +10770 -0
  186. data/generated/google/apis/dfareporting_v2_1/representations.rb +3438 -0
  187. data/generated/google/apis/dfareporting_v2_1/service.rb +8585 -0
  188. data/generated/google/apis/dfareporting_v2_1.rb +37 -0
  189. data/generated/google/apis/dfareporting_v2_3/classes.rb +10830 -0
  190. data/generated/google/apis/dfareporting_v2_3/representations.rb +3829 -0
  191. data/generated/google/apis/dfareporting_v2_3/service.rb +8581 -0
  192. data/generated/google/apis/dfareporting_v2_3.rb +37 -0
  193. data/generated/google/apis/discovery_v1/classes.rb +961 -0
  194. data/generated/google/apis/discovery_v1/representations.rb +397 -0
  195. data/generated/google/apis/discovery_v1/service.rb +142 -0
  196. data/generated/google/apis/discovery_v1.rb +32 -0
  197. data/generated/google/apis/dns_v1/classes.rb +406 -0
  198. data/generated/google/apis/dns_v1/representations.rb +167 -0
  199. data/generated/google/apis/dns_v1/service.rb +454 -0
  200. data/generated/google/apis/dns_v1.rb +44 -0
  201. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +802 -0
  202. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +371 -0
  203. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +374 -0
  204. data/generated/google/apis/doubleclickbidmanager_v1.rb +31 -0
  205. data/generated/google/apis/doubleclicksearch_v2/classes.rb +958 -0
  206. data/generated/google/apis/doubleclicksearch_v2/representations.rb +350 -0
  207. data/generated/google/apis/doubleclicksearch_v2/service.rb +480 -0
  208. data/generated/google/apis/doubleclicksearch_v2.rb +35 -0
  209. data/generated/google/apis/drive_v2/classes.rb +2569 -0
  210. data/generated/google/apis/drive_v2/representations.rb +878 -0
  211. data/generated/google/apis/drive_v2/service.rb +2740 -0
  212. data/generated/google/apis/drive_v2.rb +58 -0
  213. data/generated/google/apis/drive_v3/classes.rb +1541 -0
  214. data/generated/google/apis/drive_v3/representations.rb +548 -0
  215. data/generated/google/apis/drive_v3/service.rb +1542 -0
  216. data/generated/google/apis/drive_v3.rb +55 -0
  217. data/generated/google/apis/fitness_v1/classes.rb +885 -0
  218. data/generated/google/apis/fitness_v1/representations.rb +360 -0
  219. data/generated/google/apis/fitness_v1/service.rb +675 -0
  220. data/generated/google/apis/fitness_v1.rb +49 -0
  221. data/generated/google/apis/fusiontables_v2/classes.rb +1048 -0
  222. data/generated/google/apis/fusiontables_v2/representations.rb +457 -0
  223. data/generated/google/apis/fusiontables_v2/service.rb +1463 -0
  224. data/generated/google/apis/fusiontables_v2.rb +37 -0
  225. data/generated/google/apis/games_configuration_v1configuration/classes.rb +506 -0
  226. data/generated/google/apis/games_configuration_v1configuration/representations.rb +228 -0
  227. data/generated/google/apis/games_configuration_v1configuration/service.rb +565 -0
  228. data/generated/google/apis/games_configuration_v1configuration.rb +34 -0
  229. data/generated/google/apis/games_management_v1management/classes.rb +533 -0
  230. data/generated/google/apis/games_management_v1management/representations.rb +262 -0
  231. data/generated/google/apis/games_management_v1management/service.rb +994 -0
  232. data/generated/google/apis/games_management_v1management.rb +37 -0
  233. data/generated/google/apis/games_v1/classes.rb +4626 -0
  234. data/generated/google/apis/games_v1/representations.rb +1783 -0
  235. data/generated/google/apis/games_v1/service.rb +2290 -0
  236. data/generated/google/apis/games_v1.rb +40 -0
  237. data/generated/google/apis/gan_v1beta1/classes.rb +1428 -0
  238. data/generated/google/apis/gan_v1beta1/representations.rb +462 -0
  239. data/generated/google/apis/gan_v1beta1/service.rb +682 -0
  240. data/generated/google/apis/gan_v1beta1.rb +31 -0
  241. data/generated/google/apis/genomics_v1/classes.rb +2609 -0
  242. data/generated/google/apis/genomics_v1/representations.rb +1029 -0
  243. data/generated/google/apis/genomics_v1/service.rb +1676 -0
  244. data/generated/google/apis/genomics_v1.rb +49 -0
  245. data/generated/google/apis/genomics_v1beta2/classes.rb +3288 -0
  246. data/generated/google/apis/genomics_v1beta2/representations.rb +1194 -0
  247. data/generated/google/apis/genomics_v1beta2/service.rb +2392 -0
  248. data/generated/google/apis/genomics_v1beta2.rb +46 -0
  249. data/generated/google/apis/gmail_v1/classes.rb +794 -0
  250. data/generated/google/apis/gmail_v1/representations.rb +383 -0
  251. data/generated/google/apis/gmail_v1/service.rb +1470 -0
  252. data/generated/google/apis/gmail_v1.rb +52 -0
  253. data/generated/google/apis/groupsmigration_v1/classes.rb +51 -0
  254. data/generated/google/apis/groupsmigration_v1/representations.rb +40 -0
  255. data/generated/google/apis/groupsmigration_v1/service.rb +110 -0
  256. data/generated/google/apis/groupsmigration_v1.rb +34 -0
  257. data/generated/google/apis/groupssettings_v1/classes.rb +221 -0
  258. data/generated/google/apis/groupssettings_v1/representations.rb +66 -0
  259. data/generated/google/apis/groupssettings_v1/service.rb +179 -0
  260. data/generated/google/apis/groupssettings_v1.rb +34 -0
  261. data/generated/google/apis/identitytoolkit_v3/classes.rb +1637 -0
  262. data/generated/google/apis/identitytoolkit_v3/representations.rb +618 -0
  263. data/generated/google/apis/identitytoolkit_v3/service.rb +616 -0
  264. data/generated/google/apis/identitytoolkit_v3.rb +31 -0
  265. data/generated/google/apis/kgsearch_v1/classes.rb +59 -0
  266. data/generated/google/apis/kgsearch_v1/representations.rb +41 -0
  267. data/generated/google/apis/kgsearch_v1/service.rb +111 -0
  268. data/{spec/google/api_client/request_spec.rb → generated/google/apis/kgsearch_v1.rb} +16 -13
  269. data/generated/google/apis/licensing_v1/classes.rb +132 -0
  270. data/generated/google/apis/licensing_v1/representations.rb +74 -0
  271. data/generated/google/apis/licensing_v1/service.rb +369 -0
  272. data/generated/google/apis/licensing_v1.rb +34 -0
  273. data/generated/google/apis/logging_v1beta3/classes.rb +1079 -0
  274. data/generated/google/apis/logging_v1beta3/representations.rb +366 -0
  275. data/generated/google/apis/logging_v1beta3/service.rb +1001 -0
  276. data/generated/google/apis/logging_v1beta3.rb +47 -0
  277. data/generated/google/apis/logging_v2beta1/classes.rb +990 -0
  278. data/generated/google/apis/logging_v2beta1/representations.rb +377 -0
  279. data/generated/google/apis/logging_v2beta1/service.rb +547 -0
  280. data/generated/google/apis/logging_v2beta1.rb +47 -0
  281. data/generated/google/apis/manager_v1beta2/classes.rb +1287 -0
  282. data/generated/google/apis/manager_v1beta2/representations.rb +606 -0
  283. data/generated/google/apis/manager_v1beta2/service.rb +372 -0
  284. data/generated/google/apis/manager_v1beta2.rb +53 -0
  285. data/generated/google/apis/mirror_v1/classes.rb +1072 -0
  286. data/generated/google/apis/mirror_v1/representations.rb +390 -0
  287. data/generated/google/apis/mirror_v1/service.rb +977 -0
  288. data/generated/google/apis/mirror_v1.rb +37 -0
  289. data/generated/google/apis/oauth2_v2/classes.rb +245 -0
  290. data/generated/google/apis/oauth2_v2/representations.rb +102 -0
  291. data/generated/google/apis/oauth2_v2/service.rb +199 -0
  292. data/generated/google/apis/oauth2_v2.rb +43 -0
  293. data/generated/google/apis/pagespeedonline_v2/classes.rb +614 -0
  294. data/generated/google/apis/pagespeedonline_v2/representations.rb +272 -0
  295. data/generated/google/apis/pagespeedonline_v2/service.rb +119 -0
  296. data/generated/google/apis/pagespeedonline_v2.rb +32 -0
  297. data/generated/google/apis/partners_v2/classes.rb +942 -0
  298. data/generated/google/apis/partners_v2/representations.rb +454 -0
  299. data/generated/google/apis/partners_v2/service.rb +400 -0
  300. data/generated/google/apis/partners_v2.rb +32 -0
  301. data/generated/google/apis/people_v1/classes.rb +1521 -0
  302. data/generated/google/apis/people_v1/representations.rb +663 -0
  303. data/generated/google/apis/people_v1/service.rb +189 -0
  304. data/generated/google/apis/people_v1.rb +59 -0
  305. data/generated/google/apis/plus_domains_v1/classes.rb +2609 -0
  306. data/generated/google/apis/plus_domains_v1/representations.rb +1111 -0
  307. data/generated/google/apis/plus_domains_v1/service.rb +904 -0
  308. data/generated/google/apis/plus_domains_v1.rb +61 -0
  309. data/generated/google/apis/plus_v1/classes.rb +2094 -0
  310. data/generated/google/apis/plus_v1/representations.rb +907 -0
  311. data/generated/google/apis/plus_v1/service.rb +470 -0
  312. data/generated/google/apis/plus_v1.rb +43 -0
  313. data/generated/google/apis/prediction_v1_6/classes.rb +751 -0
  314. data/generated/google/apis/prediction_v1_6/representations.rb +369 -0
  315. data/generated/google/apis/prediction_v1_6/service.rb +380 -0
  316. data/generated/google/apis/prediction_v1_6.rb +44 -0
  317. data/generated/google/apis/proximitybeacon_v1beta1/classes.rb +639 -0
  318. data/generated/google/apis/proximitybeacon_v1beta1/representations.rb +312 -0
  319. data/generated/google/apis/proximitybeacon_v1beta1/service.rb +591 -0
  320. data/generated/google/apis/proximitybeacon_v1beta1.rb +31 -0
  321. data/generated/google/apis/pubsub_v1/classes.rb +614 -0
  322. data/generated/google/apis/pubsub_v1/representations.rb +323 -0
  323. data/generated/google/apis/pubsub_v1/service.rb +774 -0
  324. data/generated/google/apis/pubsub_v1.rb +37 -0
  325. data/generated/google/apis/pubsub_v1beta2/classes.rb +620 -0
  326. data/generated/google/apis/pubsub_v1beta2/representations.rb +282 -0
  327. data/generated/google/apis/pubsub_v1beta2/service.rb +774 -0
  328. data/generated/google/apis/pubsub_v1beta2.rb +37 -0
  329. data/generated/google/apis/qpx_express_v1/classes.rb +1268 -0
  330. data/generated/google/apis/qpx_express_v1/representations.rb +472 -0
  331. data/generated/google/apis/qpx_express_v1/service.rb +100 -0
  332. data/generated/google/apis/qpx_express_v1.rb +31 -0
  333. data/generated/google/apis/replicapool_v1beta2/classes.rb +631 -0
  334. data/generated/google/apis/replicapool_v1beta2/representations.rb +264 -0
  335. data/generated/google/apis/replicapool_v1beta2/service.rb +608 -0
  336. data/generated/google/apis/replicapool_v1beta2.rb +44 -0
  337. data/generated/google/apis/replicapoolupdater_v1beta1/classes.rb +733 -0
  338. data/generated/google/apis/replicapoolupdater_v1beta1/representations.rb +294 -0
  339. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +508 -0
  340. data/generated/google/apis/replicapoolupdater_v1beta1.rb +44 -0
  341. data/generated/google/apis/reseller_v1/classes.rb +526 -0
  342. data/generated/google/apis/reseller_v1/representations.rb +223 -0
  343. data/generated/google/apis/reseller_v1/service.rb +623 -0
  344. data/generated/google/apis/reseller_v1.rb +37 -0
  345. data/generated/google/apis/resourceviews_v1beta2/classes.rb +660 -0
  346. data/generated/google/apis/resourceviews_v1beta2/representations.rb +301 -0
  347. data/generated/google/apis/resourceviews_v1beta2/service.rb +563 -0
  348. data/generated/google/apis/resourceviews_v1beta2.rb +50 -0
  349. data/generated/google/apis/script_v1/classes.rb +259 -0
  350. data/generated/google/apis/script_v1/representations.rb +118 -0
  351. data/generated/google/apis/script_v1/service.rb +98 -0
  352. data/generated/google/apis/script_v1.rb +61 -0
  353. data/generated/google/apis/site_verification_v1/classes.rb +185 -0
  354. data/generated/google/apis/site_verification_v1/representations.rb +113 -0
  355. data/generated/google/apis/site_verification_v1/service.rb +315 -0
  356. data/generated/google/apis/site_verification_v1.rb +37 -0
  357. data/generated/google/apis/sqladmin_v1beta4/classes.rb +2030 -0
  358. data/generated/google/apis/sqladmin_v1beta4/representations.rb +856 -0
  359. data/generated/google/apis/sqladmin_v1beta4/service.rb +1625 -0
  360. data/generated/google/apis/sqladmin_v1beta4.rb +37 -0
  361. data/generated/google/apis/storage_v1/classes.rb +1222 -0
  362. data/generated/google/apis/storage_v1/representations.rb +497 -0
  363. data/generated/google/apis/storage_v1/service.rb +1903 -0
  364. data/generated/google/apis/storage_v1.rb +46 -0
  365. data/generated/google/apis/storagetransfer_v1/classes.rb +1046 -0
  366. data/generated/google/apis/storagetransfer_v1/representations.rb +418 -0
  367. data/generated/google/apis/storagetransfer_v1/service.rb +473 -0
  368. data/generated/google/apis/storagetransfer_v1.rb +35 -0
  369. data/generated/google/apis/tagmanager_v1/classes.rb +1494 -0
  370. data/generated/google/apis/tagmanager_v1/representations.rb +611 -0
  371. data/generated/google/apis/tagmanager_v1/service.rb +2119 -0
  372. data/generated/google/apis/tagmanager_v1.rb +52 -0
  373. data/generated/google/apis/taskqueue_v1beta2/classes.rb +254 -0
  374. data/generated/google/apis/taskqueue_v1beta2/representations.rb +126 -0
  375. data/generated/google/apis/taskqueue_v1beta2/service.rb +408 -0
  376. data/generated/google/apis/taskqueue_v1beta2.rb +37 -0
  377. data/generated/google/apis/tasks_v1/classes.rb +296 -0
  378. data/generated/google/apis/tasks_v1/representations.rb +125 -0
  379. data/generated/google/apis/tasks_v1/service.rb +643 -0
  380. data/generated/google/apis/tasks_v1.rb +37 -0
  381. data/generated/google/apis/translate_v2/classes.rb +168 -0
  382. data/generated/google/apis/translate_v2/representations.rb +121 -0
  383. data/generated/google/apis/translate_v2/service.rb +182 -0
  384. data/generated/google/apis/translate_v2.rb +31 -0
  385. data/generated/google/apis/urlshortener_v1/classes.rb +246 -0
  386. data/generated/google/apis/urlshortener_v1/representations.rb +121 -0
  387. data/generated/google/apis/urlshortener_v1/service.rb +176 -0
  388. data/generated/google/apis/urlshortener_v1.rb +34 -0
  389. data/generated/google/apis/vision_v1/classes.rb +1259 -0
  390. data/generated/google/apis/vision_v1/representations.rb +418 -0
  391. data/generated/google/apis/vision_v1/service.rb +91 -0
  392. data/generated/google/apis/vision_v1.rb +37 -0
  393. data/generated/google/apis/webmasters_v3/classes.rb +563 -0
  394. data/generated/google/apis/webmasters_v3/representations.rb +282 -0
  395. data/generated/google/apis/webmasters_v3/service.rb +573 -0
  396. data/generated/google/apis/webmasters_v3.rb +37 -0
  397. data/generated/google/apis/youtube_analytics_v1/classes.rb +546 -0
  398. data/generated/google/apis/youtube_analytics_v1/representations.rb +273 -0
  399. data/generated/google/apis/youtube_analytics_v1/service.rb +562 -0
  400. data/generated/google/apis/youtube_analytics_v1.rb +46 -0
  401. data/generated/google/apis/youtube_v3/classes.rb +8071 -0
  402. data/generated/google/apis/youtube_v3/representations.rb +3134 -0
  403. data/generated/google/apis/youtube_v3/service.rb +4403 -0
  404. data/generated/google/apis/youtube_v3.rb +49 -0
  405. data/generated/google/apis/youtubereporting_v1/classes.rb +258 -0
  406. data/generated/google/apis/youtubereporting_v1/representations.rb +144 -0
  407. data/generated/google/apis/youtubereporting_v1/service.rb +364 -0
  408. data/generated/google/apis/youtubereporting_v1.rb +38 -0
  409. data/google-api-client.gemspec +25 -39
  410. data/lib/google/api_client/auth/installed_app.rb +7 -5
  411. data/lib/google/api_client/auth/key_utils.rb +1 -0
  412. data/lib/google/api_client/auth/storage.rb +4 -2
  413. data/lib/google/api_client/auth/storages/file_store.rb +2 -3
  414. data/lib/google/api_client/auth/storages/redis_store.rb +7 -2
  415. data/lib/google/api_client/client_secrets.rb +7 -9
  416. data/lib/google/apis/core/api_command.rb +136 -0
  417. data/lib/google/apis/core/base_service.rb +317 -0
  418. data/lib/google/apis/core/batch.rb +239 -0
  419. data/lib/google/apis/core/download.rb +94 -0
  420. data/lib/google/apis/core/hashable.rb +44 -0
  421. data/lib/google/apis/core/http_client_adapter.rb +82 -0
  422. data/lib/google/apis/core/http_command.rb +328 -0
  423. data/lib/google/apis/core/json_representation.rb +145 -0
  424. data/lib/google/{api_client/version.rb → apis/core/logging.rb} +12 -8
  425. data/lib/google/apis/core/multipart.rb +187 -0
  426. data/lib/google/apis/core/upload.rb +289 -0
  427. data/lib/google/{api_client → apis}/errors.rb +39 -28
  428. data/lib/google/apis/generator/annotator.rb +295 -0
  429. data/lib/google/apis/generator/helpers.rb +74 -0
  430. data/lib/google/apis/generator/model.rb +143 -0
  431. data/lib/google/apis/generator/template.rb +124 -0
  432. data/lib/google/apis/generator/templates/_class.tmpl +40 -0
  433. data/lib/google/apis/generator/templates/_method.tmpl +92 -0
  434. data/lib/google/apis/generator/templates/_representation.tmpl +51 -0
  435. data/lib/google/apis/generator/templates/_representation_stub.tmpl +17 -0
  436. data/lib/google/apis/generator/templates/_representation_type.tmpl +10 -0
  437. data/lib/google/{api_client/reference.rb → apis/generator/templates/classes.rb.tmpl} +11 -9
  438. data/lib/google/apis/generator/templates/module.rb.tmpl +40 -0
  439. data/lib/google/apis/generator/templates/representations.rb.tmpl +32 -0
  440. data/lib/google/apis/generator/templates/service.rb.tmpl +60 -0
  441. data/lib/google/apis/generator.rb +70 -0
  442. data/lib/google/apis/options.rb +85 -0
  443. data/lib/google/apis/version.rb +39 -0
  444. data/lib/google/apis.rb +48 -0
  445. data/rakelib/metrics.rake +22 -0
  446. data/rakelib/rubocop.rake +10 -0
  447. data/rakelib/spec.rake +11 -0
  448. data/rakelib/yard.rake +11 -0
  449. data/samples/cli/Gemfile +7 -0
  450. data/samples/cli/README.md +51 -0
  451. data/samples/cli/google-api-samples +32 -0
  452. data/samples/cli/lib/base_cli.rb +95 -0
  453. data/samples/cli/lib/samples/analytics.rb +62 -0
  454. data/samples/cli/lib/samples/androidpublisher.rb +47 -0
  455. data/samples/cli/lib/samples/calendar.rb +83 -0
  456. data/samples/cli/lib/samples/drive.rb +82 -0
  457. data/samples/cli/lib/samples/gmail.rb +50 -0
  458. data/samples/cli/lib/samples/pubsub.rb +114 -0
  459. data/samples/cli/lib/samples/translate.rb +44 -0
  460. data/samples/cli/lib/samples/you_tube.rb +44 -0
  461. data/samples/web/Gemfile +7 -0
  462. data/samples/web/README.md +44 -0
  463. data/samples/web/app.rb +120 -0
  464. data/samples/web/views/calendar.erb +34 -0
  465. data/{lib/google/api_client/service_account.rb → samples/web/views/drive.erb} +20 -8
  466. data/samples/web/views/home.erb +35 -0
  467. data/samples/web/views/layout.erb +40 -0
  468. data/script/generate +100 -0
  469. data/script/package +8 -0
  470. data/script/release +15 -0
  471. data/spec/fixtures/files/api_names.yaml +3 -0
  472. data/spec/fixtures/files/auth_stored_credentials.json +8 -0
  473. data/spec/fixtures/files/child/.gitignore +0 -0
  474. data/spec/fixtures/files/client_secrets.json +1 -0
  475. data/spec/fixtures/files/invalid.json +1 -0
  476. data/spec/fixtures/files/test.blah +1 -0
  477. data/spec/fixtures/files/test.txt +1 -0
  478. data/spec/fixtures/files/test_api.json +440 -0
  479. data/spec/google/api_client/auth/storage_spec.rb +1 -3
  480. data/spec/google/api_client/auth/storages/file_store_spec.rb +1 -2
  481. data/spec/google/api_client/auth/storages/redis_store_spec.rb +1 -3
  482. data/spec/google/api_client/client_secrets_spec.rb +338 -2
  483. data/spec/google/apis/core/api_command_spec.rb +209 -0
  484. data/spec/google/apis/core/batch_spec.rb +142 -0
  485. data/spec/google/apis/core/download_spec.rb +103 -0
  486. data/spec/google/apis/core/hashable_spec.rb +60 -0
  487. data/spec/google/apis/core/http_command_spec.rb +303 -0
  488. data/spec/google/apis/core/json_representation_spec.rb +199 -0
  489. data/spec/google/apis/core/service_spec.rb +247 -0
  490. data/spec/google/apis/core/upload_spec.rb +300 -0
  491. data/{lib/google/api_client/discovery.rb → spec/google/apis/generated_spec.rb} +13 -5
  492. data/spec/google/apis/generator/generator_spec.rb +324 -0
  493. data/spec/google/apis/logging_spec.rb +45 -0
  494. data/spec/google/apis/options_spec.rb +40 -0
  495. data/spec/integration_tests/adsense_spec.rb +29 -0
  496. data/spec/integration_tests/drive_spec.rb +35 -0
  497. data/spec/integration_tests/pubsub_spec.rb +48 -0
  498. data/spec/integration_tests/url_shortener_spec.rb +45 -0
  499. data/spec/spec_helper/load_path_spec.rb +33 -0
  500. data/spec/spec_helper.rb +131 -44
  501. data/third_party/hurley_patches.rb +103 -0
  502. metadata +563 -188
  503. data/lib/compat/multi_json.rb +0 -19
  504. data/lib/google/api_client/auth/file_storage.rb +0 -59
  505. data/lib/google/api_client/auth/jwt_asserter.rb +0 -126
  506. data/lib/google/api_client/auth/pkcs12.rb +0 -41
  507. data/lib/google/api_client/batch.rb +0 -326
  508. data/lib/google/api_client/charset.rb +0 -33
  509. data/lib/google/api_client/discovery/api.rb +0 -310
  510. data/lib/google/api_client/discovery/media.rb +0 -77
  511. data/lib/google/api_client/discovery/method.rb +0 -363
  512. data/lib/google/api_client/discovery/resource.rb +0 -156
  513. data/lib/google/api_client/discovery/schema.rb +0 -117
  514. data/lib/google/api_client/environment.rb +0 -42
  515. data/lib/google/api_client/gzip.rb +0 -28
  516. data/lib/google/api_client/logging.rb +0 -32
  517. data/lib/google/api_client/media.rb +0 -259
  518. data/lib/google/api_client/railtie.rb +0 -18
  519. data/lib/google/api_client/request.rb +0 -350
  520. data/lib/google/api_client/result.rb +0 -255
  521. data/lib/google/api_client/service/batch.rb +0 -110
  522. data/lib/google/api_client/service/request.rb +0 -144
  523. data/lib/google/api_client/service/resource.rb +0 -40
  524. data/lib/google/api_client/service/result.rb +0 -162
  525. data/lib/google/api_client/service/simple_file_store.rb +0 -151
  526. data/lib/google/api_client/service/stub_generator.rb +0 -61
  527. data/lib/google/api_client/service.rb +0 -233
  528. data/lib/google/api_client.rb +0 -750
  529. data/spec/google/api_client/batch_spec.rb +0 -248
  530. data/spec/google/api_client/discovery_spec.rb +0 -708
  531. data/spec/google/api_client/gzip_spec.rb +0 -98
  532. data/spec/google/api_client/media_spec.rb +0 -178
  533. data/spec/google/api_client/result_spec.rb +0 -207
  534. data/spec/google/api_client/service_account_spec.rb +0 -169
  535. data/spec/google/api_client/service_spec.rb +0 -618
  536. data/spec/google/api_client/simple_file_store_spec.rb +0 -133
  537. data/spec/google/api_client_spec.rb +0 -352
@@ -0,0 +1,2503 @@
1
+ # Copyright 2015 Google Inc.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module BigqueryV2
24
+
25
+ #
26
+ class CsvOptions
27
+ include Google::Apis::Core::Hashable
28
+
29
+ # [Optional] Indicates if BigQuery should accept rows that are missing trailing
30
+ # optional columns. If true, BigQuery treats missing trailing columns as null
31
+ # values. If false, records with missing trailing columns are treated as bad
32
+ # records, and if there are too many bad records, an invalid error is returned
33
+ # in the job result. The default value is false.
34
+ # Corresponds to the JSON property `allowJaggedRows`
35
+ # @return [Boolean]
36
+ attr_accessor :allow_jagged_rows
37
+ alias_method :allow_jagged_rows?, :allow_jagged_rows
38
+
39
+ # [Optional] Indicates if BigQuery should allow quoted data sections that
40
+ # contain newline characters in a CSV file. The default value is false.
41
+ # Corresponds to the JSON property `allowQuotedNewlines`
42
+ # @return [Boolean]
43
+ attr_accessor :allow_quoted_newlines
44
+ alias_method :allow_quoted_newlines?, :allow_quoted_newlines
45
+
46
+ # [Optional] The character encoding of the data. The supported values are UTF-8
47
+ # or ISO-8859-1. The default value is UTF-8. BigQuery decodes the data after the
48
+ # raw, binary data has been split using the values of the quote and
49
+ # fieldDelimiter properties.
50
+ # Corresponds to the JSON property `encoding`
51
+ # @return [String]
52
+ attr_accessor :encoding
53
+
54
+ # [Optional] The separator for fields in a CSV file. BigQuery converts the
55
+ # string to ISO-8859-1 encoding, and then uses the first byte of the encoded
56
+ # string to split the data in its raw, binary state. BigQuery also supports the
57
+ # escape sequence "\t" to specify a tab separator. The default value is a comma (
58
+ # ',').
59
+ # Corresponds to the JSON property `fieldDelimiter`
60
+ # @return [String]
61
+ attr_accessor :field_delimiter
62
+
63
+ # [Optional] The value that is used to quote data sections in a CSV file.
64
+ # BigQuery converts the string to ISO-8859-1 encoding, and then uses the first
65
+ # byte of the encoded string to split the data in its raw, binary state. The
66
+ # default value is a double-quote ('"'). If your data does not contain quoted
67
+ # sections, set the property value to an empty string. If your data contains
68
+ # quoted newline characters, you must also set the allowQuotedNewlines property
69
+ # to true.
70
+ # Corresponds to the JSON property `quote`
71
+ # @return [String]
72
+ attr_accessor :quote
73
+
74
+ # [Optional] The number of rows at the top of a CSV file that BigQuery will skip
75
+ # when reading the data. The default value is 0. This property is useful if you
76
+ # have header rows in the file that should be skipped.
77
+ # Corresponds to the JSON property `skipLeadingRows`
78
+ # @return [Fixnum]
79
+ attr_accessor :skip_leading_rows
80
+
81
+ def initialize(**args)
82
+ update!(**args)
83
+ end
84
+
85
+ # Update properties of this object
86
+ def update!(**args)
87
+ @allow_jagged_rows = args[:allow_jagged_rows] if args.key?(:allow_jagged_rows)
88
+ @allow_quoted_newlines = args[:allow_quoted_newlines] if args.key?(:allow_quoted_newlines)
89
+ @encoding = args[:encoding] if args.key?(:encoding)
90
+ @field_delimiter = args[:field_delimiter] if args.key?(:field_delimiter)
91
+ @quote = args[:quote] if args.key?(:quote)
92
+ @skip_leading_rows = args[:skip_leading_rows] if args.key?(:skip_leading_rows)
93
+ end
94
+ end
95
+
96
+ #
97
+ class Dataset
98
+ include Google::Apis::Core::Hashable
99
+
100
+ # [Optional] An array of objects that define dataset access for one or more
101
+ # entities. You can set this property when inserting or updating a dataset in
102
+ # order to control who is allowed to access the data. If unspecified at dataset
103
+ # creation time, BigQuery adds default dataset access for the following entities:
104
+ # access.specialGroup: projectReaders; access.role: READER; access.specialGroup:
105
+ # projectWriters; access.role: WRITER; access.specialGroup: projectOwners;
106
+ # access.role: OWNER; access.userByEmail: [dataset creator email]; access.role:
107
+ # OWNER;
108
+ # Corresponds to the JSON property `access`
109
+ # @return [Array<Google::Apis::BigqueryV2::Dataset::Access>]
110
+ attr_accessor :access
111
+
112
+ # [Output-only] The time when this dataset was created, in milliseconds since
113
+ # the epoch.
114
+ # Corresponds to the JSON property `creationTime`
115
+ # @return [String]
116
+ attr_accessor :creation_time
117
+
118
+ # [Required] A reference that identifies the dataset.
119
+ # Corresponds to the JSON property `datasetReference`
120
+ # @return [Google::Apis::BigqueryV2::DatasetReference]
121
+ attr_accessor :dataset_reference
122
+
123
+ # [Experimental] The default lifetime of all tables in the dataset, in
124
+ # milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this
125
+ # property is set, all newly-created tables in the dataset will have an
126
+ # expirationTime property set to the creation time plus the value in this
127
+ # property, and changing the value will only affect new tables, not existing
128
+ # ones. When the expirationTime for a given table is reached, that table will be
129
+ # deleted automatically. If a table's expirationTime is modified or removed
130
+ # before the table expires, or if you provide an explicit expirationTime when
131
+ # creating a table, that value takes precedence over the default expiration time
132
+ # indicated by this property.
133
+ # Corresponds to the JSON property `defaultTableExpirationMs`
134
+ # @return [String]
135
+ attr_accessor :default_table_expiration_ms
136
+
137
+ # [Optional] A user-friendly description of the dataset.
138
+ # Corresponds to the JSON property `description`
139
+ # @return [String]
140
+ attr_accessor :description
141
+
142
+ # [Output-only] A hash of the resource.
143
+ # Corresponds to the JSON property `etag`
144
+ # @return [String]
145
+ attr_accessor :etag
146
+
147
+ # [Optional] A descriptive name for the dataset.
148
+ # Corresponds to the JSON property `friendlyName`
149
+ # @return [String]
150
+ attr_accessor :friendly_name
151
+
152
+ # [Output-only] The fully-qualified unique name of the dataset in the format
153
+ # projectId:datasetId. The dataset name without the project name is given in the
154
+ # datasetId field. When creating a new dataset, leave this field blank, and
155
+ # instead specify the datasetId field.
156
+ # Corresponds to the JSON property `id`
157
+ # @return [String]
158
+ attr_accessor :id
159
+
160
+ # [Output-only] The resource type.
161
+ # Corresponds to the JSON property `kind`
162
+ # @return [String]
163
+ attr_accessor :kind
164
+
165
+ # [Output-only] The date when this dataset or any of its tables was last
166
+ # modified, in milliseconds since the epoch.
167
+ # Corresponds to the JSON property `lastModifiedTime`
168
+ # @return [String]
169
+ attr_accessor :last_modified_time
170
+
171
+ # [Experimental] The geographic location where the dataset should reside.
172
+ # Possible values include EU and US. The default value is US.
173
+ # Corresponds to the JSON property `location`
174
+ # @return [String]
175
+ attr_accessor :location
176
+
177
+ # [Output-only] A URL that can be used to access the resource again. You can use
178
+ # this URL in Get or Update requests to the resource.
179
+ # Corresponds to the JSON property `selfLink`
180
+ # @return [String]
181
+ attr_accessor :self_link
182
+
183
+ def initialize(**args)
184
+ update!(**args)
185
+ end
186
+
187
+ # Update properties of this object
188
+ def update!(**args)
189
+ @access = args[:access] if args.key?(:access)
190
+ @creation_time = args[:creation_time] if args.key?(:creation_time)
191
+ @dataset_reference = args[:dataset_reference] if args.key?(:dataset_reference)
192
+ @default_table_expiration_ms = args[:default_table_expiration_ms] if args.key?(:default_table_expiration_ms)
193
+ @description = args[:description] if args.key?(:description)
194
+ @etag = args[:etag] if args.key?(:etag)
195
+ @friendly_name = args[:friendly_name] if args.key?(:friendly_name)
196
+ @id = args[:id] if args.key?(:id)
197
+ @kind = args[:kind] if args.key?(:kind)
198
+ @last_modified_time = args[:last_modified_time] if args.key?(:last_modified_time)
199
+ @location = args[:location] if args.key?(:location)
200
+ @self_link = args[:self_link] if args.key?(:self_link)
201
+ end
202
+
203
+ #
204
+ class Access
205
+ include Google::Apis::Core::Hashable
206
+
207
+ # [Pick one] A domain to grant access to. Any users signed in with the domain
208
+ # specified will be granted the specified access. Example: "example.com".
209
+ # Corresponds to the JSON property `domain`
210
+ # @return [String]
211
+ attr_accessor :domain
212
+
213
+ # [Pick one] An email address of a Google Group to grant access to.
214
+ # Corresponds to the JSON property `groupByEmail`
215
+ # @return [String]
216
+ attr_accessor :group_by_email
217
+
218
+ # [Required] Describes the rights granted to the user specified by the other
219
+ # member of the access object. The following string values are supported: READER,
220
+ # WRITER, OWNER.
221
+ # Corresponds to the JSON property `role`
222
+ # @return [String]
223
+ attr_accessor :role
224
+
225
+ # [Pick one] A special group to grant access to. Possible values include:
226
+ # projectOwners: Owners of the enclosing project. projectReaders: Readers of the
227
+ # enclosing project. projectWriters: Writers of the enclosing project.
228
+ # allAuthenticatedUsers: All authenticated BigQuery users.
229
+ # Corresponds to the JSON property `specialGroup`
230
+ # @return [String]
231
+ attr_accessor :special_group
232
+
233
+ # [Pick one] An email address of a user to grant access to. For example: fred@
234
+ # example.com.
235
+ # Corresponds to the JSON property `userByEmail`
236
+ # @return [String]
237
+ attr_accessor :user_by_email
238
+
239
+ # [Pick one] A view from a different dataset to grant access to. Queries
240
+ # executed against that view will have read access to tables in this dataset.
241
+ # The role field is not required when this field is set. If that view is updated
242
+ # by any user, access to the view needs to be granted again via an update
243
+ # operation.
244
+ # Corresponds to the JSON property `view`
245
+ # @return [Google::Apis::BigqueryV2::TableReference]
246
+ attr_accessor :view
247
+
248
+ def initialize(**args)
249
+ update!(**args)
250
+ end
251
+
252
+ # Update properties of this object
253
+ def update!(**args)
254
+ @domain = args[:domain] if args.key?(:domain)
255
+ @group_by_email = args[:group_by_email] if args.key?(:group_by_email)
256
+ @role = args[:role] if args.key?(:role)
257
+ @special_group = args[:special_group] if args.key?(:special_group)
258
+ @user_by_email = args[:user_by_email] if args.key?(:user_by_email)
259
+ @view = args[:view] if args.key?(:view)
260
+ end
261
+ end
262
+ end
263
+
264
+ #
265
+ class DatasetList
266
+ include Google::Apis::Core::Hashable
267
+
268
+ # An array of the dataset resources in the project. Each resource contains basic
269
+ # information. For full information about a particular dataset resource, use the
270
+ # Datasets: get method. This property is omitted when there are no datasets in
271
+ # the project.
272
+ # Corresponds to the JSON property `datasets`
273
+ # @return [Array<Google::Apis::BigqueryV2::DatasetList::Dataset>]
274
+ attr_accessor :datasets
275
+
276
+ # A hash value of the results page. You can use this property to determine if
277
+ # the page has changed since the last request.
278
+ # Corresponds to the JSON property `etag`
279
+ # @return [String]
280
+ attr_accessor :etag
281
+
282
+ # The list type. This property always returns the value "bigquery#datasetList".
283
+ # Corresponds to the JSON property `kind`
284
+ # @return [String]
285
+ attr_accessor :kind
286
+
287
+ # A token that can be used to request the next results page. This property is
288
+ # omitted on the final results page.
289
+ # Corresponds to the JSON property `nextPageToken`
290
+ # @return [String]
291
+ attr_accessor :next_page_token
292
+
293
+ def initialize(**args)
294
+ update!(**args)
295
+ end
296
+
297
+ # Update properties of this object
298
+ def update!(**args)
299
+ @datasets = args[:datasets] if args.key?(:datasets)
300
+ @etag = args[:etag] if args.key?(:etag)
301
+ @kind = args[:kind] if args.key?(:kind)
302
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
303
+ end
304
+
305
+ #
306
+ class Dataset
307
+ include Google::Apis::Core::Hashable
308
+
309
+ # The dataset reference. Use this property to access specific parts of the
310
+ # dataset's ID, such as project ID or dataset ID.
311
+ # Corresponds to the JSON property `datasetReference`
312
+ # @return [Google::Apis::BigqueryV2::DatasetReference]
313
+ attr_accessor :dataset_reference
314
+
315
+ # A descriptive name for the dataset, if one exists.
316
+ # Corresponds to the JSON property `friendlyName`
317
+ # @return [String]
318
+ attr_accessor :friendly_name
319
+
320
+ # The fully-qualified, unique, opaque ID of the dataset.
321
+ # Corresponds to the JSON property `id`
322
+ # @return [String]
323
+ attr_accessor :id
324
+
325
+ # The resource type. This property always returns the value "bigquery#dataset".
326
+ # Corresponds to the JSON property `kind`
327
+ # @return [String]
328
+ attr_accessor :kind
329
+
330
+ def initialize(**args)
331
+ update!(**args)
332
+ end
333
+
334
+ # Update properties of this object
335
+ def update!(**args)
336
+ @dataset_reference = args[:dataset_reference] if args.key?(:dataset_reference)
337
+ @friendly_name = args[:friendly_name] if args.key?(:friendly_name)
338
+ @id = args[:id] if args.key?(:id)
339
+ @kind = args[:kind] if args.key?(:kind)
340
+ end
341
+ end
342
+ end
343
+
344
+ #
345
+ class DatasetReference
346
+ include Google::Apis::Core::Hashable
347
+
348
+ # [Required] A unique ID for this dataset, without the project name. The ID must
349
+ # contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The
350
+ # maximum length is 1,024 characters.
351
+ # Corresponds to the JSON property `datasetId`
352
+ # @return [String]
353
+ attr_accessor :dataset_id
354
+
355
+ # [Optional] The ID of the project containing this dataset.
356
+ # Corresponds to the JSON property `projectId`
357
+ # @return [String]
358
+ attr_accessor :project_id
359
+
360
+ def initialize(**args)
361
+ update!(**args)
362
+ end
363
+
364
+ # Update properties of this object
365
+ def update!(**args)
366
+ @dataset_id = args[:dataset_id] if args.key?(:dataset_id)
367
+ @project_id = args[:project_id] if args.key?(:project_id)
368
+ end
369
+ end
370
+
371
+ #
372
+ class ErrorProto
373
+ include Google::Apis::Core::Hashable
374
+
375
+ # Debugging information. This property is internal to Google and should not be
376
+ # used.
377
+ # Corresponds to the JSON property `debugInfo`
378
+ # @return [String]
379
+ attr_accessor :debug_info
380
+
381
+ # Specifies where the error occurred, if present.
382
+ # Corresponds to the JSON property `location`
383
+ # @return [String]
384
+ attr_accessor :location
385
+
386
+ # A human-readable description of the error.
387
+ # Corresponds to the JSON property `message`
388
+ # @return [String]
389
+ attr_accessor :message
390
+
391
+ # A short error code that summarizes the error.
392
+ # Corresponds to the JSON property `reason`
393
+ # @return [String]
394
+ attr_accessor :reason
395
+
396
+ def initialize(**args)
397
+ update!(**args)
398
+ end
399
+
400
+ # Update properties of this object
401
+ def update!(**args)
402
+ @debug_info = args[:debug_info] if args.key?(:debug_info)
403
+ @location = args[:location] if args.key?(:location)
404
+ @message = args[:message] if args.key?(:message)
405
+ @reason = args[:reason] if args.key?(:reason)
406
+ end
407
+ end
408
+
409
+ #
410
+ class ExplainQueryStage
411
+ include Google::Apis::Core::Hashable
412
+
413
+ # Relative amount of time the average shard spent on CPU-bound tasks.
414
+ # Corresponds to the JSON property `computeRatioAvg`
415
+ # @return [Float]
416
+ attr_accessor :compute_ratio_avg
417
+
418
+ # Relative amount of time the slowest shard spent on CPU-bound tasks.
419
+ # Corresponds to the JSON property `computeRatioMax`
420
+ # @return [Float]
421
+ attr_accessor :compute_ratio_max
422
+
423
+ # Unique ID for stage within plan.
424
+ # Corresponds to the JSON property `id`
425
+ # @return [String]
426
+ attr_accessor :id
427
+
428
+ # Human-readable name for stage.
429
+ # Corresponds to the JSON property `name`
430
+ # @return [String]
431
+ attr_accessor :name
432
+
433
+ # Relative amount of time the average shard spent reading input.
434
+ # Corresponds to the JSON property `readRatioAvg`
435
+ # @return [Float]
436
+ attr_accessor :read_ratio_avg
437
+
438
+ # Relative amount of time the slowest shard spent reading input.
439
+ # Corresponds to the JSON property `readRatioMax`
440
+ # @return [Float]
441
+ attr_accessor :read_ratio_max
442
+
443
+ # Number of records read into the stage.
444
+ # Corresponds to the JSON property `recordsRead`
445
+ # @return [String]
446
+ attr_accessor :records_read
447
+
448
+ # Number of records written by the stage.
449
+ # Corresponds to the JSON property `recordsWritten`
450
+ # @return [String]
451
+ attr_accessor :records_written
452
+
453
+ # List of operations within the stage in dependency order (approximately
454
+ # chronological).
455
+ # Corresponds to the JSON property `steps`
456
+ # @return [Array<Google::Apis::BigqueryV2::ExplainQueryStep>]
457
+ attr_accessor :steps
458
+
459
+ # Relative amount of time the average shard spent waiting to be scheduled.
460
+ # Corresponds to the JSON property `waitRatioAvg`
461
+ # @return [Float]
462
+ attr_accessor :wait_ratio_avg
463
+
464
+ # Relative amount of time the slowest shard spent waiting to be scheduled.
465
+ # Corresponds to the JSON property `waitRatioMax`
466
+ # @return [Float]
467
+ attr_accessor :wait_ratio_max
468
+
469
+ # Relative amount of time the average shard spent on writing output.
470
+ # Corresponds to the JSON property `writeRatioAvg`
471
+ # @return [Float]
472
+ attr_accessor :write_ratio_avg
473
+
474
+ # Relative amount of time the slowest shard spent on writing output.
475
+ # Corresponds to the JSON property `writeRatioMax`
476
+ # @return [Float]
477
+ attr_accessor :write_ratio_max
478
+
479
+ def initialize(**args)
480
+ update!(**args)
481
+ end
482
+
483
+ # Update properties of this object
484
+ def update!(**args)
485
+ @compute_ratio_avg = args[:compute_ratio_avg] if args.key?(:compute_ratio_avg)
486
+ @compute_ratio_max = args[:compute_ratio_max] if args.key?(:compute_ratio_max)
487
+ @id = args[:id] if args.key?(:id)
488
+ @name = args[:name] if args.key?(:name)
489
+ @read_ratio_avg = args[:read_ratio_avg] if args.key?(:read_ratio_avg)
490
+ @read_ratio_max = args[:read_ratio_max] if args.key?(:read_ratio_max)
491
+ @records_read = args[:records_read] if args.key?(:records_read)
492
+ @records_written = args[:records_written] if args.key?(:records_written)
493
+ @steps = args[:steps] if args.key?(:steps)
494
+ @wait_ratio_avg = args[:wait_ratio_avg] if args.key?(:wait_ratio_avg)
495
+ @wait_ratio_max = args[:wait_ratio_max] if args.key?(:wait_ratio_max)
496
+ @write_ratio_avg = args[:write_ratio_avg] if args.key?(:write_ratio_avg)
497
+ @write_ratio_max = args[:write_ratio_max] if args.key?(:write_ratio_max)
498
+ end
499
+ end
500
+
501
+ #
502
+ class ExplainQueryStep
503
+ include Google::Apis::Core::Hashable
504
+
505
+ # Machine-readable operation type.
506
+ # Corresponds to the JSON property `kind`
507
+ # @return [String]
508
+ attr_accessor :kind
509
+
510
+ # Human-readable stage descriptions.
511
+ # Corresponds to the JSON property `substeps`
512
+ # @return [Array<String>]
513
+ attr_accessor :substeps
514
+
515
+ def initialize(**args)
516
+ update!(**args)
517
+ end
518
+
519
+ # Update properties of this object
520
+ def update!(**args)
521
+ @kind = args[:kind] if args.key?(:kind)
522
+ @substeps = args[:substeps] if args.key?(:substeps)
523
+ end
524
+ end
525
+
526
+ #
527
+ class ExternalDataConfiguration
528
+ include Google::Apis::Core::Hashable
529
+
530
+ # [Optional] The compression type of the data source. Possible values include
531
+ # GZIP and NONE. The default value is NONE. This setting is ignored for Google
532
+ # Cloud Datastore backups.
533
+ # Corresponds to the JSON property `compression`
534
+ # @return [String]
535
+ attr_accessor :compression
536
+
537
+ # Additional properties to set if sourceFormat is set to CSV.
538
+ # Corresponds to the JSON property `csvOptions`
539
+ # @return [Google::Apis::BigqueryV2::CsvOptions]
540
+ attr_accessor :csv_options
541
+
542
+ # [Optional] Indicates if BigQuery should allow extra values that are not
543
+ # represented in the table schema. If true, the extra values are ignored. If
544
+ # false, records with extra columns are treated as bad records, and if there are
545
+ # too many bad records, an invalid error is returned in the job result. The
546
+ # default value is false. The sourceFormat property determines what BigQuery
547
+ # treats as an extra value: CSV: Trailing columns JSON: Named values that don't
548
+ # match any column names Google Cloud Datastore backups: This setting is ignored.
549
+ # Corresponds to the JSON property `ignoreUnknownValues`
550
+ # @return [Boolean]
551
+ attr_accessor :ignore_unknown_values
552
+ alias_method :ignore_unknown_values?, :ignore_unknown_values
553
+
554
+ # [Optional] The maximum number of bad records that BigQuery can ignore when
555
+ # reading data. If the number of bad records exceeds this value, an invalid
556
+ # error is returned in the job result. The default value is 0, which requires
557
+ # that all records are valid. This setting is ignored for Google Cloud Datastore
558
+ # backups.
559
+ # Corresponds to the JSON property `maxBadRecords`
560
+ # @return [Fixnum]
561
+ attr_accessor :max_bad_records
562
+
563
+ # [Optional] The schema for the data. Schema is required for CSV and JSON
564
+ # formats. Schema is disallowed for Google Cloud Datastore backups.
565
+ # Corresponds to the JSON property `schema`
566
+ # @return [Google::Apis::BigqueryV2::TableSchema]
567
+ attr_accessor :schema
568
+
569
+ # [Required] The data format. For CSV files, specify "CSV". For newline-
570
+ # delimited JSON, specify "NEWLINE_DELIMITED_JSON". For Google Cloud Datastore
571
+ # backups, specify "DATASTORE_BACKUP".
572
+ # Corresponds to the JSON property `sourceFormat`
573
+ # @return [String]
574
+ attr_accessor :source_format
575
+
576
+ # [Required] The fully-qualified URIs that point to your data in Google Cloud
577
+ # Storage. Each URI can contain one '*' wildcard character and it must come
578
+ # after the 'bucket' name. Size limits related to load jobs apply to external
579
+ # data sources, plus an additional limit of 10 GB maximum size across all URIs.
580
+ # For Google Cloud Datastore backups, exactly one URI can be specified, and it
581
+ # must end with '.backup_info'. Also, the '*' wildcard character is not allowed.
582
+ # Corresponds to the JSON property `sourceUris`
583
+ # @return [Array<String>]
584
+ attr_accessor :source_uris
585
+
586
+ def initialize(**args)
587
+ update!(**args)
588
+ end
589
+
590
+ # Update properties of this object
591
+ def update!(**args)
592
+ @compression = args[:compression] if args.key?(:compression)
593
+ @csv_options = args[:csv_options] if args.key?(:csv_options)
594
+ @ignore_unknown_values = args[:ignore_unknown_values] if args.key?(:ignore_unknown_values)
595
+ @max_bad_records = args[:max_bad_records] if args.key?(:max_bad_records)
596
+ @schema = args[:schema] if args.key?(:schema)
597
+ @source_format = args[:source_format] if args.key?(:source_format)
598
+ @source_uris = args[:source_uris] if args.key?(:source_uris)
599
+ end
600
+ end
601
+
602
+ #
603
+ class GetQueryResultsResponse
604
+ include Google::Apis::Core::Hashable
605
+
606
+ # Whether the query result was fetched from the query cache.
607
+ # Corresponds to the JSON property `cacheHit`
608
+ # @return [Boolean]
609
+ attr_accessor :cache_hit
610
+ alias_method :cache_hit?, :cache_hit
611
+
612
+ # [Output-only] All errors and warnings encountered during the running of the
613
+ # job. Errors here do not necessarily mean that the job has completed or was
614
+ # unsuccessful.
615
+ # Corresponds to the JSON property `errors`
616
+ # @return [Array<Google::Apis::BigqueryV2::ErrorProto>]
617
+ attr_accessor :errors
618
+
619
+ # A hash of this response.
620
+ # Corresponds to the JSON property `etag`
621
+ # @return [String]
622
+ attr_accessor :etag
623
+
624
+ # Whether the query has completed or not. If rows or totalRows are present, this
625
+ # will always be true. If this is false, totalRows will not be available.
626
+ # Corresponds to the JSON property `jobComplete`
627
+ # @return [Boolean]
628
+ attr_accessor :job_complete
629
+ alias_method :job_complete?, :job_complete
630
+
631
+ # Reference to the BigQuery Job that was created to run the query. This field
632
+ # will be present even if the original request timed out, in which case
633
+ # GetQueryResults can be used to read the results once the query has completed.
634
+ # Since this API only returns the first page of results, subsequent pages can be
635
+ # fetched via the same mechanism (GetQueryResults).
636
+ # Corresponds to the JSON property `jobReference`
637
+ # @return [Google::Apis::BigqueryV2::JobReference]
638
+ attr_accessor :job_reference
639
+
640
+ # The resource type of the response.
641
+ # Corresponds to the JSON property `kind`
642
+ # @return [String]
643
+ attr_accessor :kind
644
+
645
+ # A token used for paging results.
646
+ # Corresponds to the JSON property `pageToken`
647
+ # @return [String]
648
+ attr_accessor :page_token
649
+
650
+ # An object with as many results as can be contained within the maximum
651
+ # permitted reply size. To get any additional rows, you can call GetQueryResults
652
+ # and specify the jobReference returned above. Present only when the query
653
+ # completes successfully.
654
+ # Corresponds to the JSON property `rows`
655
+ # @return [Array<Google::Apis::BigqueryV2::TableRow>]
656
+ attr_accessor :rows
657
+
658
+ # The schema of the results. Present only when the query completes successfully.
659
+ # Corresponds to the JSON property `schema`
660
+ # @return [Google::Apis::BigqueryV2::TableSchema]
661
+ attr_accessor :schema
662
+
663
+ # The total number of bytes processed for this query.
664
+ # Corresponds to the JSON property `totalBytesProcessed`
665
+ # @return [String]
666
+ attr_accessor :total_bytes_processed
667
+
668
+ # The total number of rows in the complete query result set, which can be more
669
+ # than the number of rows in this single page of results. Present only when the
670
+ # query completes successfully.
671
+ # Corresponds to the JSON property `totalRows`
672
+ # @return [String]
673
+ attr_accessor :total_rows
674
+
675
+ def initialize(**args)
676
+ update!(**args)
677
+ end
678
+
679
+ # Update properties of this object
680
+ def update!(**args)
681
+ @cache_hit = args[:cache_hit] if args.key?(:cache_hit)
682
+ @errors = args[:errors] if args.key?(:errors)
683
+ @etag = args[:etag] if args.key?(:etag)
684
+ @job_complete = args[:job_complete] if args.key?(:job_complete)
685
+ @job_reference = args[:job_reference] if args.key?(:job_reference)
686
+ @kind = args[:kind] if args.key?(:kind)
687
+ @page_token = args[:page_token] if args.key?(:page_token)
688
+ @rows = args[:rows] if args.key?(:rows)
689
+ @schema = args[:schema] if args.key?(:schema)
690
+ @total_bytes_processed = args[:total_bytes_processed] if args.key?(:total_bytes_processed)
691
+ @total_rows = args[:total_rows] if args.key?(:total_rows)
692
+ end
693
+ end
694
+
695
+ #
696
+ class Job
697
+ include Google::Apis::Core::Hashable
698
+
699
+ # [Required] Describes the job configuration.
700
+ # Corresponds to the JSON property `configuration`
701
+ # @return [Google::Apis::BigqueryV2::JobConfiguration]
702
+ attr_accessor :configuration
703
+
704
+ # [Output-only] A hash of this resource.
705
+ # Corresponds to the JSON property `etag`
706
+ # @return [String]
707
+ attr_accessor :etag
708
+
709
+ # [Output-only] Opaque ID field of the job
710
+ # Corresponds to the JSON property `id`
711
+ # @return [String]
712
+ attr_accessor :id
713
+
714
+ # [Optional] Reference describing the unique-per-user name of the job.
715
+ # Corresponds to the JSON property `jobReference`
716
+ # @return [Google::Apis::BigqueryV2::JobReference]
717
+ attr_accessor :job_reference
718
+
719
+ # [Output-only] The type of the resource.
720
+ # Corresponds to the JSON property `kind`
721
+ # @return [String]
722
+ attr_accessor :kind
723
+
724
+ # [Output-only] A URL that can be used to access this resource again.
725
+ # Corresponds to the JSON property `selfLink`
726
+ # @return [String]
727
+ attr_accessor :self_link
728
+
729
+ # [Output-only] Information about the job, including starting time and ending
730
+ # time of the job.
731
+ # Corresponds to the JSON property `statistics`
732
+ # @return [Google::Apis::BigqueryV2::JobStatistics]
733
+ attr_accessor :statistics
734
+
735
+ # [Output-only] The status of this job. Examine this value when polling an
736
+ # asynchronous job to see if the job is complete.
737
+ # Corresponds to the JSON property `status`
738
+ # @return [Google::Apis::BigqueryV2::JobStatus]
739
+ attr_accessor :status
740
+
741
+ # [Output-only] Email address of the user who ran the job.
742
+ # Corresponds to the JSON property `user_email`
743
+ # @return [String]
744
+ attr_accessor :user_email
745
+
746
+ def initialize(**args)
747
+ update!(**args)
748
+ end
749
+
750
+ # Update properties of this object
751
+ def update!(**args)
752
+ @configuration = args[:configuration] if args.key?(:configuration)
753
+ @etag = args[:etag] if args.key?(:etag)
754
+ @id = args[:id] if args.key?(:id)
755
+ @job_reference = args[:job_reference] if args.key?(:job_reference)
756
+ @kind = args[:kind] if args.key?(:kind)
757
+ @self_link = args[:self_link] if args.key?(:self_link)
758
+ @statistics = args[:statistics] if args.key?(:statistics)
759
+ @status = args[:status] if args.key?(:status)
760
+ @user_email = args[:user_email] if args.key?(:user_email)
761
+ end
762
+ end
763
+
764
+ #
765
+ class CancelJobResponse
766
+ include Google::Apis::Core::Hashable
767
+
768
+ # The final state of the job.
769
+ # Corresponds to the JSON property `job`
770
+ # @return [Google::Apis::BigqueryV2::Job]
771
+ attr_accessor :job
772
+
773
+ # The resource type of the response.
774
+ # Corresponds to the JSON property `kind`
775
+ # @return [String]
776
+ attr_accessor :kind
777
+
778
+ def initialize(**args)
779
+ update!(**args)
780
+ end
781
+
782
+ # Update properties of this object
783
+ def update!(**args)
784
+ @job = args[:job] if args.key?(:job)
785
+ @kind = args[:kind] if args.key?(:kind)
786
+ end
787
+ end
788
+
789
+ #
790
+ class JobConfiguration
791
+ include Google::Apis::Core::Hashable
792
+
793
+ # [Pick one] Copies a table.
794
+ # Corresponds to the JSON property `copy`
795
+ # @return [Google::Apis::BigqueryV2::JobConfigurationTableCopy]
796
+ attr_accessor :copy
797
+
798
+ # [Optional] If set, don't actually run this job. A valid query will return a
799
+ # mostly empty response with some processing statistics, while an invalid query
800
+ # will return the same error it would if it wasn't a dry run. Behavior of non-
801
+ # query jobs is undefined.
802
+ # Corresponds to the JSON property `dryRun`
803
+ # @return [Boolean]
804
+ attr_accessor :dry_run
805
+ alias_method :dry_run?, :dry_run
806
+
807
+ # [Pick one] Configures an extract job.
808
+ # Corresponds to the JSON property `extract`
809
+ # @return [Google::Apis::BigqueryV2::JobConfigurationExtract]
810
+ attr_accessor :extract
811
+
812
+ # [Pick one] Configures a load job.
813
+ # Corresponds to the JSON property `load`
814
+ # @return [Google::Apis::BigqueryV2::JobConfigurationLoad]
815
+ attr_accessor :load
816
+
817
+ # [Pick one] Configures a query job.
818
+ # Corresponds to the JSON property `query`
819
+ # @return [Google::Apis::BigqueryV2::JobConfigurationQuery]
820
+ attr_accessor :query
821
+
822
+ def initialize(**args)
823
+ update!(**args)
824
+ end
825
+
826
+ # Update properties of this object
827
+ def update!(**args)
828
+ @copy = args[:copy] if args.key?(:copy)
829
+ @dry_run = args[:dry_run] if args.key?(:dry_run)
830
+ @extract = args[:extract] if args.key?(:extract)
831
+ @load = args[:load] if args.key?(:load)
832
+ @query = args[:query] if args.key?(:query)
833
+ end
834
+ end
835
+
836
+ #
837
+ class JobConfigurationExtract
838
+ include Google::Apis::Core::Hashable
839
+
840
+ # [Optional] The compression type to use for exported files. Possible values
841
+ # include GZIP and NONE. The default value is NONE.
842
+ # Corresponds to the JSON property `compression`
843
+ # @return [String]
844
+ attr_accessor :compression
845
+
846
+ # [Optional] The exported file format. Possible values include CSV,
847
+ # NEWLINE_DELIMITED_JSON and AVRO. The default value is CSV. Tables with nested
848
+ # or repeated fields cannot be exported as CSV.
849
+ # Corresponds to the JSON property `destinationFormat`
850
+ # @return [String]
851
+ attr_accessor :destination_format
852
+
853
+ # [Pick one] DEPRECATED: Use destinationUris instead, passing only one URI as
854
+ # necessary. The fully-qualified Google Cloud Storage URI where the extracted
855
+ # table should be written.
856
+ # Corresponds to the JSON property `destinationUri`
857
+ # @return [String]
858
+ attr_accessor :destination_uri
859
+
860
+ # [Pick one] A list of fully-qualified Google Cloud Storage URIs where the
861
+ # extracted table should be written.
862
+ # Corresponds to the JSON property `destinationUris`
863
+ # @return [Array<String>]
864
+ attr_accessor :destination_uris
865
+
866
+ # [Optional] Delimiter to use between fields in the exported data. Default is ','
867
+ # Corresponds to the JSON property `fieldDelimiter`
868
+ # @return [String]
869
+ attr_accessor :field_delimiter
870
+
871
+ # [Optional] Whether to print out a header row in the results. Default is true.
872
+ # Corresponds to the JSON property `printHeader`
873
+ # @return [Boolean]
874
+ attr_accessor :print_header
875
+ alias_method :print_header?, :print_header
876
+
877
+ # [Required] A reference to the table being exported.
878
+ # Corresponds to the JSON property `sourceTable`
879
+ # @return [Google::Apis::BigqueryV2::TableReference]
880
+ attr_accessor :source_table
881
+
882
+ def initialize(**args)
883
+ update!(**args)
884
+ end
885
+
886
+ # Update properties of this object
887
+ def update!(**args)
888
+ @compression = args[:compression] if args.key?(:compression)
889
+ @destination_format = args[:destination_format] if args.key?(:destination_format)
890
+ @destination_uri = args[:destination_uri] if args.key?(:destination_uri)
891
+ @destination_uris = args[:destination_uris] if args.key?(:destination_uris)
892
+ @field_delimiter = args[:field_delimiter] if args.key?(:field_delimiter)
893
+ @print_header = args[:print_header] if args.key?(:print_header)
894
+ @source_table = args[:source_table] if args.key?(:source_table)
895
+ end
896
+ end
897
+
898
+ #
899
+ class JobConfigurationLoad
900
+ include Google::Apis::Core::Hashable
901
+
902
+ # [Optional] Accept rows that are missing trailing optional columns. The missing
903
+ # values are treated as nulls. If false, records with missing trailing columns
904
+ # are treated as bad records, and if there are too many bad records, an invalid
905
+ # error is returned in the job result. The default value is false. Only
906
+ # applicable to CSV, ignored for other formats.
907
+ # Corresponds to the JSON property `allowJaggedRows`
908
+ # @return [Boolean]
909
+ attr_accessor :allow_jagged_rows
910
+ alias_method :allow_jagged_rows?, :allow_jagged_rows
911
+
912
+ # Indicates if BigQuery should allow quoted data sections that contain newline
913
+ # characters in a CSV file. The default value is false.
914
+ # Corresponds to the JSON property `allowQuotedNewlines`
915
+ # @return [Boolean]
916
+ attr_accessor :allow_quoted_newlines
917
+ alias_method :allow_quoted_newlines?, :allow_quoted_newlines
918
+
919
+ # [Optional] Specifies whether the job is allowed to create new tables. The
920
+ # following values are supported: CREATE_IF_NEEDED: If the table does not exist,
921
+ # BigQuery creates the table. CREATE_NEVER: The table must already exist. If it
922
+ # does not, a 'notFound' error is returned in the job result. The default value
923
+ # is CREATE_IF_NEEDED. Creation, truncation and append actions occur as one
924
+ # atomic update upon job completion.
925
+ # Corresponds to the JSON property `createDisposition`
926
+ # @return [String]
927
+ attr_accessor :create_disposition
928
+
929
+ # [Required] The destination table to load the data into.
930
+ # Corresponds to the JSON property `destinationTable`
931
+ # @return [Google::Apis::BigqueryV2::TableReference]
932
+ attr_accessor :destination_table
933
+
934
+ # [Optional] The character encoding of the data. The supported values are UTF-8
935
+ # or ISO-8859-1. The default value is UTF-8. BigQuery decodes the data after the
936
+ # raw, binary data has been split using the values of the quote and
937
+ # fieldDelimiter properties.
938
+ # Corresponds to the JSON property `encoding`
939
+ # @return [String]
940
+ attr_accessor :encoding
941
+
942
+ # [Optional] The separator for fields in a CSV file. The separator can be any
943
+ # ISO-8859-1 single-byte character. To use a character in the range 128-255, you
944
+ # must encode the character as UTF8. BigQuery converts the string to ISO-8859-1
945
+ # encoding, and then uses the first byte of the encoded string to split the data
946
+ # in its raw, binary state. BigQuery also supports the escape sequence "\t" to
947
+ # specify a tab separator. The default value is a comma (',').
948
+ # Corresponds to the JSON property `fieldDelimiter`
949
+ # @return [String]
950
+ attr_accessor :field_delimiter
951
+
952
+ # [Optional] Indicates if BigQuery should allow extra values that are not
953
+ # represented in the table schema. If true, the extra values are ignored. If
954
+ # false, records with extra columns are treated as bad records, and if there are
955
+ # too many bad records, an invalid error is returned in the job result. The
956
+ # default value is false. The sourceFormat property determines what BigQuery
957
+ # treats as an extra value: CSV: Trailing columns JSON: Named values that don't
958
+ # match any column names
959
+ # Corresponds to the JSON property `ignoreUnknownValues`
960
+ # @return [Boolean]
961
+ attr_accessor :ignore_unknown_values
962
+ alias_method :ignore_unknown_values?, :ignore_unknown_values
963
+
964
+ # [Optional] The maximum number of bad records that BigQuery can ignore when
965
+ # running the job. If the number of bad records exceeds this value, an invalid
966
+ # error is returned in the job result. The default value is 0, which requires
967
+ # that all records are valid.
968
+ # Corresponds to the JSON property `maxBadRecords`
969
+ # @return [Fixnum]
970
+ attr_accessor :max_bad_records
971
+
972
+ # [Experimental] If sourceFormat is set to "DATASTORE_BACKUP", indicates which
973
+ # entity properties to load into BigQuery from a Cloud Datastore backup.
974
+ # Property names are case sensitive and must be top-level properties. If no
975
+ # properties are specified, BigQuery loads all properties. If any named property
976
+ # isn't found in the Cloud Datastore backup, an invalid error is returned in the
977
+ # job result.
978
+ # Corresponds to the JSON property `projectionFields`
979
+ # @return [Array<String>]
980
+ attr_accessor :projection_fields
981
+
982
+ # [Optional] The value that is used to quote data sections in a CSV file.
983
+ # BigQuery converts the string to ISO-8859-1 encoding, and then uses the first
984
+ # byte of the encoded string to split the data in its raw, binary state. The
985
+ # default value is a double-quote ('"'). If your data does not contain quoted
986
+ # sections, set the property value to an empty string. If your data contains
987
+ # quoted newline characters, you must also set the allowQuotedNewlines property
988
+ # to true.
989
+ # Corresponds to the JSON property `quote`
990
+ # @return [String]
991
+ attr_accessor :quote
992
+
993
+ # [Optional] The schema for the destination table. The schema can be omitted if
994
+ # the destination table already exists, or if you're loading data from Google
995
+ # Cloud Datastore.
996
+ # Corresponds to the JSON property `schema`
997
+ # @return [Google::Apis::BigqueryV2::TableSchema]
998
+ attr_accessor :schema
999
+
1000
+ # [Deprecated] The inline schema. For CSV schemas, specify as "Field1:Type1[,
1001
+ # Field2:Type2]*". For example, "foo:STRING, bar:INTEGER, baz:FLOAT".
1002
+ # Corresponds to the JSON property `schemaInline`
1003
+ # @return [String]
1004
+ attr_accessor :schema_inline
1005
+
1006
+ # [Deprecated] The format of the schemaInline property.
1007
+ # Corresponds to the JSON property `schemaInlineFormat`
1008
+ # @return [String]
1009
+ attr_accessor :schema_inline_format
1010
+
1011
+ # [Optional] The number of rows at the top of a CSV file that BigQuery will skip
1012
+ # when loading the data. The default value is 0. This property is useful if you
1013
+ # have header rows in the file that should be skipped.
1014
+ # Corresponds to the JSON property `skipLeadingRows`
1015
+ # @return [Fixnum]
1016
+ attr_accessor :skip_leading_rows
1017
+
1018
+ # [Optional] The format of the data files. For CSV files, specify "CSV". For
1019
+ # datastore backups, specify "DATASTORE_BACKUP". For newline-delimited JSON,
1020
+ # specify "NEWLINE_DELIMITED_JSON". The default value is CSV.
1021
+ # Corresponds to the JSON property `sourceFormat`
1022
+ # @return [String]
1023
+ attr_accessor :source_format
1024
+
1025
+ # [Required] The fully-qualified URIs that point to your data in Google Cloud
1026
+ # Storage. Each URI can contain one '*' wildcard character and it must come
1027
+ # after the 'bucket' name.
1028
+ # Corresponds to the JSON property `sourceUris`
1029
+ # @return [Array<String>]
1030
+ attr_accessor :source_uris
1031
+
1032
+ # [Optional] Specifies the action that occurs if the destination table already
1033
+ # exists. The following values are supported: WRITE_TRUNCATE: If the table
1034
+ # already exists, BigQuery overwrites the table data. WRITE_APPEND: If the table
1035
+ # already exists, BigQuery appends the data to the table. WRITE_EMPTY: If the
1036
+ # table already exists and contains data, a 'duplicate' error is returned in the
1037
+ # job result. The default value is WRITE_APPEND. Each action is atomic and only
1038
+ # occurs if BigQuery is able to complete the job successfully. Creation,
1039
+ # truncation and append actions occur as one atomic update upon job completion.
1040
+ # Corresponds to the JSON property `writeDisposition`
1041
+ # @return [String]
1042
+ attr_accessor :write_disposition
1043
+
1044
+ def initialize(**args)
1045
+ update!(**args)
1046
+ end
1047
+
1048
+ # Update properties of this object
1049
+ def update!(**args)
1050
+ @allow_jagged_rows = args[:allow_jagged_rows] if args.key?(:allow_jagged_rows)
1051
+ @allow_quoted_newlines = args[:allow_quoted_newlines] if args.key?(:allow_quoted_newlines)
1052
+ @create_disposition = args[:create_disposition] if args.key?(:create_disposition)
1053
+ @destination_table = args[:destination_table] if args.key?(:destination_table)
1054
+ @encoding = args[:encoding] if args.key?(:encoding)
1055
+ @field_delimiter = args[:field_delimiter] if args.key?(:field_delimiter)
1056
+ @ignore_unknown_values = args[:ignore_unknown_values] if args.key?(:ignore_unknown_values)
1057
+ @max_bad_records = args[:max_bad_records] if args.key?(:max_bad_records)
1058
+ @projection_fields = args[:projection_fields] if args.key?(:projection_fields)
1059
+ @quote = args[:quote] if args.key?(:quote)
1060
+ @schema = args[:schema] if args.key?(:schema)
1061
+ @schema_inline = args[:schema_inline] if args.key?(:schema_inline)
1062
+ @schema_inline_format = args[:schema_inline_format] if args.key?(:schema_inline_format)
1063
+ @skip_leading_rows = args[:skip_leading_rows] if args.key?(:skip_leading_rows)
1064
+ @source_format = args[:source_format] if args.key?(:source_format)
1065
+ @source_uris = args[:source_uris] if args.key?(:source_uris)
1066
+ @write_disposition = args[:write_disposition] if args.key?(:write_disposition)
1067
+ end
1068
+ end
1069
+
1070
+ #
1071
+ class JobConfigurationQuery
1072
+ include Google::Apis::Core::Hashable
1073
+
1074
+ # If true, allows the query to produce arbitrarily large result tables at a
1075
+ # slight cost in performance. Requires destinationTable to be set.
1076
+ # Corresponds to the JSON property `allowLargeResults`
1077
+ # @return [Boolean]
1078
+ attr_accessor :allow_large_results
1079
+ alias_method :allow_large_results?, :allow_large_results
1080
+
1081
+ # [Optional] Specifies whether the job is allowed to create new tables. The
1082
+ # following values are supported: CREATE_IF_NEEDED: If the table does not exist,
1083
+ # BigQuery creates the table. CREATE_NEVER: The table must already exist. If it
1084
+ # does not, a 'notFound' error is returned in the job result. The default value
1085
+ # is CREATE_IF_NEEDED. Creation, truncation and append actions occur as one
1086
+ # atomic update upon job completion.
1087
+ # Corresponds to the JSON property `createDisposition`
1088
+ # @return [String]
1089
+ attr_accessor :create_disposition
1090
+
1091
+ # [Optional] Specifies the default dataset to use for unqualified table names in
1092
+ # the query.
1093
+ # Corresponds to the JSON property `defaultDataset`
1094
+ # @return [Google::Apis::BigqueryV2::DatasetReference]
1095
+ attr_accessor :default_dataset
1096
+
1097
+ # [Optional] Describes the table where the query results should be stored. If
1098
+ # not present, a new table will be created to store the results.
1099
+ # Corresponds to the JSON property `destinationTable`
1100
+ # @return [Google::Apis::BigqueryV2::TableReference]
1101
+ attr_accessor :destination_table
1102
+
1103
+ # [Optional] Flattens all nested and repeated fields in the query results. The
1104
+ # default value is true. allowLargeResults must be true if this is set to false.
1105
+ # Corresponds to the JSON property `flattenResults`
1106
+ # @return [Boolean]
1107
+ attr_accessor :flatten_results
1108
+ alias_method :flatten_results?, :flatten_results
1109
+
1110
+ # [Optional] Limits the billing tier for this job. Queries that have resource
1111
+ # usage beyond this tier will fail (without incurring a charge). If unspecified,
1112
+ # this will be set to your project default.
1113
+ # Corresponds to the JSON property `maximumBillingTier`
1114
+ # @return [Fixnum]
1115
+ attr_accessor :maximum_billing_tier
1116
+
1117
+ # [Deprecated] This property is deprecated.
1118
+ # Corresponds to the JSON property `preserveNulls`
1119
+ # @return [Boolean]
1120
+ attr_accessor :preserve_nulls
1121
+ alias_method :preserve_nulls?, :preserve_nulls
1122
+
1123
+ # [Optional] Specifies a priority for the query. Possible values include
1124
+ # INTERACTIVE and BATCH. The default value is INTERACTIVE.
1125
+ # Corresponds to the JSON property `priority`
1126
+ # @return [String]
1127
+ attr_accessor :priority
1128
+
1129
+ # [Required] BigQuery SQL query to execute.
1130
+ # Corresponds to the JSON property `query`
1131
+ # @return [String]
1132
+ attr_accessor :query
1133
+
1134
+ # [Optional] If querying an external data source outside of BigQuery, describes
1135
+ # the data format, location and other properties of the data source. By defining
1136
+ # these properties, the data source can then be queried as if it were a standard
1137
+ # BigQuery table.
1138
+ # Corresponds to the JSON property `tableDefinitions`
1139
+ # @return [Hash<String,Google::Apis::BigqueryV2::ExternalDataConfiguration>]
1140
+ attr_accessor :table_definitions
1141
+
1142
+ # [Experimental] Specifies whether to use BigQuery's legacy SQL dialect for this
1143
+ # query. The default value is true. If set to false, the query will use BigQuery'
1144
+ # s updated SQL dialect with improved standards compliance. When using BigQuery'
1145
+ # s updated SQL, the values of allowLargeResults and flattenResults are ignored.
1146
+ # Queries with useLegacySql set to false will be run as if allowLargeResults is
1147
+ # true and flattenResults is false.
1148
+ # Corresponds to the JSON property `useLegacySql`
1149
+ # @return [Boolean]
1150
+ attr_accessor :use_legacy_sql
1151
+ alias_method :use_legacy_sql?, :use_legacy_sql
1152
+
1153
+ # [Optional] Whether to look for the result in the query cache. The query cache
1154
+ # is a best-effort cache that will be flushed whenever tables in the query are
1155
+ # modified. Moreover, the query cache is only available when a query does not
1156
+ # have a destination table specified. The default value is true.
1157
+ # Corresponds to the JSON property `useQueryCache`
1158
+ # @return [Boolean]
1159
+ attr_accessor :use_query_cache
1160
+ alias_method :use_query_cache?, :use_query_cache
1161
+
1162
+ # [Experimental] Describes user-defined function resources used in the query.
1163
+ # Corresponds to the JSON property `userDefinedFunctionResources`
1164
+ # @return [Array<Google::Apis::BigqueryV2::UserDefinedFunctionResource>]
1165
+ attr_accessor :user_defined_function_resources
1166
+
1167
+ # [Optional] Specifies the action that occurs if the destination table already
1168
+ # exists. The following values are supported: WRITE_TRUNCATE: If the table
1169
+ # already exists, BigQuery overwrites the table data. WRITE_APPEND: If the table
1170
+ # already exists, BigQuery appends the data to the table. WRITE_EMPTY: If the
1171
+ # table already exists and contains data, a 'duplicate' error is returned in the
1172
+ # job result. The default value is WRITE_EMPTY. Each action is atomic and only
1173
+ # occurs if BigQuery is able to complete the job successfully. Creation,
1174
+ # truncation and append actions occur as one atomic update upon job completion.
1175
+ # Corresponds to the JSON property `writeDisposition`
1176
+ # @return [String]
1177
+ attr_accessor :write_disposition
1178
+
1179
+ def initialize(**args)
1180
+ update!(**args)
1181
+ end
1182
+
1183
+ # Update properties of this object
1184
+ def update!(**args)
1185
+ @allow_large_results = args[:allow_large_results] if args.key?(:allow_large_results)
1186
+ @create_disposition = args[:create_disposition] if args.key?(:create_disposition)
1187
+ @default_dataset = args[:default_dataset] if args.key?(:default_dataset)
1188
+ @destination_table = args[:destination_table] if args.key?(:destination_table)
1189
+ @flatten_results = args[:flatten_results] if args.key?(:flatten_results)
1190
+ @maximum_billing_tier = args[:maximum_billing_tier] if args.key?(:maximum_billing_tier)
1191
+ @preserve_nulls = args[:preserve_nulls] if args.key?(:preserve_nulls)
1192
+ @priority = args[:priority] if args.key?(:priority)
1193
+ @query = args[:query] if args.key?(:query)
1194
+ @table_definitions = args[:table_definitions] if args.key?(:table_definitions)
1195
+ @use_legacy_sql = args[:use_legacy_sql] if args.key?(:use_legacy_sql)
1196
+ @use_query_cache = args[:use_query_cache] if args.key?(:use_query_cache)
1197
+ @user_defined_function_resources = args[:user_defined_function_resources] if args.key?(:user_defined_function_resources)
1198
+ @write_disposition = args[:write_disposition] if args.key?(:write_disposition)
1199
+ end
1200
+ end
1201
+
1202
+ #
1203
+ class JobConfigurationTableCopy
1204
+ include Google::Apis::Core::Hashable
1205
+
1206
+ # [Optional] Specifies whether the job is allowed to create new tables. The
1207
+ # following values are supported: CREATE_IF_NEEDED: If the table does not exist,
1208
+ # BigQuery creates the table. CREATE_NEVER: The table must already exist. If it
1209
+ # does not, a 'notFound' error is returned in the job result. The default value
1210
+ # is CREATE_IF_NEEDED. Creation, truncation and append actions occur as one
1211
+ # atomic update upon job completion.
1212
+ # Corresponds to the JSON property `createDisposition`
1213
+ # @return [String]
1214
+ attr_accessor :create_disposition
1215
+
1216
+ # [Required] The destination table
1217
+ # Corresponds to the JSON property `destinationTable`
1218
+ # @return [Google::Apis::BigqueryV2::TableReference]
1219
+ attr_accessor :destination_table
1220
+
1221
+ # [Pick one] Source table to copy.
1222
+ # Corresponds to the JSON property `sourceTable`
1223
+ # @return [Google::Apis::BigqueryV2::TableReference]
1224
+ attr_accessor :source_table
1225
+
1226
+ # [Pick one] Source tables to copy.
1227
+ # Corresponds to the JSON property `sourceTables`
1228
+ # @return [Array<Google::Apis::BigqueryV2::TableReference>]
1229
+ attr_accessor :source_tables
1230
+
1231
+ # [Optional] Specifies the action that occurs if the destination table already
1232
+ # exists. The following values are supported: WRITE_TRUNCATE: If the table
1233
+ # already exists, BigQuery overwrites the table data. WRITE_APPEND: If the table
1234
+ # already exists, BigQuery appends the data to the table. WRITE_EMPTY: If the
1235
+ # table already exists and contains data, a 'duplicate' error is returned in the
1236
+ # job result. The default value is WRITE_EMPTY. Each action is atomic and only
1237
+ # occurs if BigQuery is able to complete the job successfully. Creation,
1238
+ # truncation and append actions occur as one atomic update upon job completion.
1239
+ # Corresponds to the JSON property `writeDisposition`
1240
+ # @return [String]
1241
+ attr_accessor :write_disposition
1242
+
1243
+ def initialize(**args)
1244
+ update!(**args)
1245
+ end
1246
+
1247
+ # Update properties of this object
1248
+ def update!(**args)
1249
+ @create_disposition = args[:create_disposition] if args.key?(:create_disposition)
1250
+ @destination_table = args[:destination_table] if args.key?(:destination_table)
1251
+ @source_table = args[:source_table] if args.key?(:source_table)
1252
+ @source_tables = args[:source_tables] if args.key?(:source_tables)
1253
+ @write_disposition = args[:write_disposition] if args.key?(:write_disposition)
1254
+ end
1255
+ end
1256
+
1257
+ #
1258
+ class JobList
1259
+ include Google::Apis::Core::Hashable
1260
+
1261
+ # A hash of this page of results.
1262
+ # Corresponds to the JSON property `etag`
1263
+ # @return [String]
1264
+ attr_accessor :etag
1265
+
1266
+ # List of jobs that were requested.
1267
+ # Corresponds to the JSON property `jobs`
1268
+ # @return [Array<Google::Apis::BigqueryV2::JobList::Job>]
1269
+ attr_accessor :jobs
1270
+
1271
+ # The resource type of the response.
1272
+ # Corresponds to the JSON property `kind`
1273
+ # @return [String]
1274
+ attr_accessor :kind
1275
+
1276
+ # A token to request the next page of results.
1277
+ # Corresponds to the JSON property `nextPageToken`
1278
+ # @return [String]
1279
+ attr_accessor :next_page_token
1280
+
1281
+ def initialize(**args)
1282
+ update!(**args)
1283
+ end
1284
+
1285
+ # Update properties of this object
1286
+ def update!(**args)
1287
+ @etag = args[:etag] if args.key?(:etag)
1288
+ @jobs = args[:jobs] if args.key?(:jobs)
1289
+ @kind = args[:kind] if args.key?(:kind)
1290
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1291
+ end
1292
+
1293
+ #
1294
+ class Job
1295
+ include Google::Apis::Core::Hashable
1296
+
1297
+ # [Full-projection-only] Specifies the job configuration.
1298
+ # Corresponds to the JSON property `configuration`
1299
+ # @return [Google::Apis::BigqueryV2::JobConfiguration]
1300
+ attr_accessor :configuration
1301
+
1302
+ # A result object that will be present only if the job has failed.
1303
+ # Corresponds to the JSON property `errorResult`
1304
+ # @return [Google::Apis::BigqueryV2::ErrorProto]
1305
+ attr_accessor :error_result
1306
+
1307
+ # Unique opaque ID of the job.
1308
+ # Corresponds to the JSON property `id`
1309
+ # @return [String]
1310
+ attr_accessor :id
1311
+
1312
+ # Job reference uniquely identifying the job.
1313
+ # Corresponds to the JSON property `jobReference`
1314
+ # @return [Google::Apis::BigqueryV2::JobReference]
1315
+ attr_accessor :job_reference
1316
+
1317
+ # The resource type.
1318
+ # Corresponds to the JSON property `kind`
1319
+ # @return [String]
1320
+ attr_accessor :kind
1321
+
1322
+ # Running state of the job. When the state is DONE, errorResult can be checked
1323
+ # to determine whether the job succeeded or failed.
1324
+ # Corresponds to the JSON property `state`
1325
+ # @return [String]
1326
+ attr_accessor :state
1327
+
1328
+ # [Output-only] Information about the job, including starting time and ending
1329
+ # time of the job.
1330
+ # Corresponds to the JSON property `statistics`
1331
+ # @return [Google::Apis::BigqueryV2::JobStatistics]
1332
+ attr_accessor :statistics
1333
+
1334
+ # [Full-projection-only] Describes the state of the job.
1335
+ # Corresponds to the JSON property `status`
1336
+ # @return [Google::Apis::BigqueryV2::JobStatus]
1337
+ attr_accessor :status
1338
+
1339
+ # [Full-projection-only] Email address of the user who ran the job.
1340
+ # Corresponds to the JSON property `user_email`
1341
+ # @return [String]
1342
+ attr_accessor :user_email
1343
+
1344
+ def initialize(**args)
1345
+ update!(**args)
1346
+ end
1347
+
1348
+ # Update properties of this object
1349
+ def update!(**args)
1350
+ @configuration = args[:configuration] if args.key?(:configuration)
1351
+ @error_result = args[:error_result] if args.key?(:error_result)
1352
+ @id = args[:id] if args.key?(:id)
1353
+ @job_reference = args[:job_reference] if args.key?(:job_reference)
1354
+ @kind = args[:kind] if args.key?(:kind)
1355
+ @state = args[:state] if args.key?(:state)
1356
+ @statistics = args[:statistics] if args.key?(:statistics)
1357
+ @status = args[:status] if args.key?(:status)
1358
+ @user_email = args[:user_email] if args.key?(:user_email)
1359
+ end
1360
+ end
1361
+ end
1362
+
1363
+ #
1364
+ class JobReference
1365
+ include Google::Apis::Core::Hashable
1366
+
1367
+ # [Required] The ID of the job. The ID must contain only letters (a-z, A-Z),
1368
+ # numbers (0-9), underscores (_), or dashes (-). The maximum length is 1,024
1369
+ # characters.
1370
+ # Corresponds to the JSON property `jobId`
1371
+ # @return [String]
1372
+ attr_accessor :job_id
1373
+
1374
+ # [Required] The ID of the project containing this job.
1375
+ # Corresponds to the JSON property `projectId`
1376
+ # @return [String]
1377
+ attr_accessor :project_id
1378
+
1379
+ def initialize(**args)
1380
+ update!(**args)
1381
+ end
1382
+
1383
+ # Update properties of this object
1384
+ def update!(**args)
1385
+ @job_id = args[:job_id] if args.key?(:job_id)
1386
+ @project_id = args[:project_id] if args.key?(:project_id)
1387
+ end
1388
+ end
1389
+
1390
+ #
1391
+ class JobStatistics
1392
+ include Google::Apis::Core::Hashable
1393
+
1394
+ # [Output-only] Creation time of this job, in milliseconds since the epoch. This
1395
+ # field will be present on all jobs.
1396
+ # Corresponds to the JSON property `creationTime`
1397
+ # @return [String]
1398
+ attr_accessor :creation_time
1399
+
1400
+ # [Output-only] End time of this job, in milliseconds since the epoch. This
1401
+ # field will be present whenever a job is in the DONE state.
1402
+ # Corresponds to the JSON property `endTime`
1403
+ # @return [String]
1404
+ attr_accessor :end_time
1405
+
1406
+ # [Output-only] Statistics for an extract job.
1407
+ # Corresponds to the JSON property `extract`
1408
+ # @return [Google::Apis::BigqueryV2::JobStatistics4]
1409
+ attr_accessor :extract
1410
+
1411
+ # [Output-only] Statistics for a load job.
1412
+ # Corresponds to the JSON property `load`
1413
+ # @return [Google::Apis::BigqueryV2::JobStatistics3]
1414
+ attr_accessor :load
1415
+
1416
+ # [Output-only] Statistics for a query job.
1417
+ # Corresponds to the JSON property `query`
1418
+ # @return [Google::Apis::BigqueryV2::JobStatistics2]
1419
+ attr_accessor :query
1420
+
1421
+ # [Output-only] Start time of this job, in milliseconds since the epoch. This
1422
+ # field will be present when the job transitions from the PENDING state to
1423
+ # either RUNNING or DONE.
1424
+ # Corresponds to the JSON property `startTime`
1425
+ # @return [String]
1426
+ attr_accessor :start_time
1427
+
1428
+ # [Output-only] [Deprecated] Use the bytes processed in the query statistics
1429
+ # instead.
1430
+ # Corresponds to the JSON property `totalBytesProcessed`
1431
+ # @return [String]
1432
+ attr_accessor :total_bytes_processed
1433
+
1434
+ def initialize(**args)
1435
+ update!(**args)
1436
+ end
1437
+
1438
+ # Update properties of this object
1439
+ def update!(**args)
1440
+ @creation_time = args[:creation_time] if args.key?(:creation_time)
1441
+ @end_time = args[:end_time] if args.key?(:end_time)
1442
+ @extract = args[:extract] if args.key?(:extract)
1443
+ @load = args[:load] if args.key?(:load)
1444
+ @query = args[:query] if args.key?(:query)
1445
+ @start_time = args[:start_time] if args.key?(:start_time)
1446
+ @total_bytes_processed = args[:total_bytes_processed] if args.key?(:total_bytes_processed)
1447
+ end
1448
+ end
1449
+
1450
+ #
1451
+ class JobStatistics2
1452
+ include Google::Apis::Core::Hashable
1453
+
1454
+ # [Output-only] Billing tier for the job.
1455
+ # Corresponds to the JSON property `billingTier`
1456
+ # @return [Fixnum]
1457
+ attr_accessor :billing_tier
1458
+
1459
+ # [Output-only] Whether the query result was fetched from the query cache.
1460
+ # Corresponds to the JSON property `cacheHit`
1461
+ # @return [Boolean]
1462
+ attr_accessor :cache_hit
1463
+ alias_method :cache_hit?, :cache_hit
1464
+
1465
+ # [Output-only, Experimental] Describes execution plan for the query as a list
1466
+ # of stages.
1467
+ # Corresponds to the JSON property `queryPlan`
1468
+ # @return [Array<Google::Apis::BigqueryV2::ExplainQueryStage>]
1469
+ attr_accessor :query_plan
1470
+
1471
+ # [Output-only, Experimental] Referenced tables for the job. Queries that
1472
+ # reference more than 50 tables will not have a complete list.
1473
+ # Corresponds to the JSON property `referencedTables`
1474
+ # @return [Array<Google::Apis::BigqueryV2::TableReference>]
1475
+ attr_accessor :referenced_tables
1476
+
1477
+ # [Output-only] Total bytes billed for the job.
1478
+ # Corresponds to the JSON property `totalBytesBilled`
1479
+ # @return [String]
1480
+ attr_accessor :total_bytes_billed
1481
+
1482
+ # [Output-only] Total bytes processed for the job.
1483
+ # Corresponds to the JSON property `totalBytesProcessed`
1484
+ # @return [String]
1485
+ attr_accessor :total_bytes_processed
1486
+
1487
+ def initialize(**args)
1488
+ update!(**args)
1489
+ end
1490
+
1491
+ # Update properties of this object
1492
+ def update!(**args)
1493
+ @billing_tier = args[:billing_tier] if args.key?(:billing_tier)
1494
+ @cache_hit = args[:cache_hit] if args.key?(:cache_hit)
1495
+ @query_plan = args[:query_plan] if args.key?(:query_plan)
1496
+ @referenced_tables = args[:referenced_tables] if args.key?(:referenced_tables)
1497
+ @total_bytes_billed = args[:total_bytes_billed] if args.key?(:total_bytes_billed)
1498
+ @total_bytes_processed = args[:total_bytes_processed] if args.key?(:total_bytes_processed)
1499
+ end
1500
+ end
1501
+
1502
+ #
1503
+ class JobStatistics3
1504
+ include Google::Apis::Core::Hashable
1505
+
1506
+ # [Output-only] Number of bytes of source data in a load job.
1507
+ # Corresponds to the JSON property `inputFileBytes`
1508
+ # @return [String]
1509
+ attr_accessor :input_file_bytes
1510
+
1511
+ # [Output-only] Number of source files in a load job.
1512
+ # Corresponds to the JSON property `inputFiles`
1513
+ # @return [String]
1514
+ attr_accessor :input_files
1515
+
1516
+ # [Output-only] Size of the loaded data in bytes. Note that while a load job is
1517
+ # in the running state, this value may change.
1518
+ # Corresponds to the JSON property `outputBytes`
1519
+ # @return [String]
1520
+ attr_accessor :output_bytes
1521
+
1522
+ # [Output-only] Number of rows imported in a load job. Note that while an import
1523
+ # job is in the running state, this value may change.
1524
+ # Corresponds to the JSON property `outputRows`
1525
+ # @return [String]
1526
+ attr_accessor :output_rows
1527
+
1528
+ def initialize(**args)
1529
+ update!(**args)
1530
+ end
1531
+
1532
+ # Update properties of this object
1533
+ def update!(**args)
1534
+ @input_file_bytes = args[:input_file_bytes] if args.key?(:input_file_bytes)
1535
+ @input_files = args[:input_files] if args.key?(:input_files)
1536
+ @output_bytes = args[:output_bytes] if args.key?(:output_bytes)
1537
+ @output_rows = args[:output_rows] if args.key?(:output_rows)
1538
+ end
1539
+ end
1540
+
1541
+ #
1542
+ class JobStatistics4
1543
+ include Google::Apis::Core::Hashable
1544
+
1545
+ # [Output-only] Number of files per destination URI or URI pattern specified in
1546
+ # the extract configuration. These values will be in the same order as the URIs
1547
+ # specified in the 'destinationUris' field.
1548
+ # Corresponds to the JSON property `destinationUriFileCounts`
1549
+ # @return [Array<String>]
1550
+ attr_accessor :destination_uri_file_counts
1551
+
1552
+ def initialize(**args)
1553
+ update!(**args)
1554
+ end
1555
+
1556
+ # Update properties of this object
1557
+ def update!(**args)
1558
+ @destination_uri_file_counts = args[:destination_uri_file_counts] if args.key?(:destination_uri_file_counts)
1559
+ end
1560
+ end
1561
+
1562
+ #
1563
+ class JobStatus
1564
+ include Google::Apis::Core::Hashable
1565
+
1566
+ # [Output-only] Final error result of the job. If present, indicates that the
1567
+ # job has completed and was unsuccessful.
1568
+ # Corresponds to the JSON property `errorResult`
1569
+ # @return [Google::Apis::BigqueryV2::ErrorProto]
1570
+ attr_accessor :error_result
1571
+
1572
+ # [Output-only] All errors encountered during the running of the job. Errors
1573
+ # here do not necessarily mean that the job has completed or was unsuccessful.
1574
+ # Corresponds to the JSON property `errors`
1575
+ # @return [Array<Google::Apis::BigqueryV2::ErrorProto>]
1576
+ attr_accessor :errors
1577
+
1578
+ # [Output-only] Running state of the job.
1579
+ # Corresponds to the JSON property `state`
1580
+ # @return [String]
1581
+ attr_accessor :state
1582
+
1583
+ def initialize(**args)
1584
+ update!(**args)
1585
+ end
1586
+
1587
+ # Update properties of this object
1588
+ def update!(**args)
1589
+ @error_result = args[:error_result] if args.key?(:error_result)
1590
+ @errors = args[:errors] if args.key?(:errors)
1591
+ @state = args[:state] if args.key?(:state)
1592
+ end
1593
+ end
1594
+
1595
+ #
1596
+ class ProjectList
1597
+ include Google::Apis::Core::Hashable
1598
+
1599
+ # A hash of the page of results
1600
+ # Corresponds to the JSON property `etag`
1601
+ # @return [String]
1602
+ attr_accessor :etag
1603
+
1604
+ # The type of list.
1605
+ # Corresponds to the JSON property `kind`
1606
+ # @return [String]
1607
+ attr_accessor :kind
1608
+
1609
+ # A token to request the next page of results.
1610
+ # Corresponds to the JSON property `nextPageToken`
1611
+ # @return [String]
1612
+ attr_accessor :next_page_token
1613
+
1614
+ # Projects to which you have at least READ access.
1615
+ # Corresponds to the JSON property `projects`
1616
+ # @return [Array<Google::Apis::BigqueryV2::ProjectList::Project>]
1617
+ attr_accessor :projects
1618
+
1619
+ # The total number of projects in the list.
1620
+ # Corresponds to the JSON property `totalItems`
1621
+ # @return [Fixnum]
1622
+ attr_accessor :total_items
1623
+
1624
+ def initialize(**args)
1625
+ update!(**args)
1626
+ end
1627
+
1628
+ # Update properties of this object
1629
+ def update!(**args)
1630
+ @etag = args[:etag] if args.key?(:etag)
1631
+ @kind = args[:kind] if args.key?(:kind)
1632
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1633
+ @projects = args[:projects] if args.key?(:projects)
1634
+ @total_items = args[:total_items] if args.key?(:total_items)
1635
+ end
1636
+
1637
+ #
1638
+ class Project
1639
+ include Google::Apis::Core::Hashable
1640
+
1641
+ # A descriptive name for this project.
1642
+ # Corresponds to the JSON property `friendlyName`
1643
+ # @return [String]
1644
+ attr_accessor :friendly_name
1645
+
1646
+ # An opaque ID of this project.
1647
+ # Corresponds to the JSON property `id`
1648
+ # @return [String]
1649
+ attr_accessor :id
1650
+
1651
+ # The resource type.
1652
+ # Corresponds to the JSON property `kind`
1653
+ # @return [String]
1654
+ attr_accessor :kind
1655
+
1656
+ # The numeric ID of this project.
1657
+ # Corresponds to the JSON property `numericId`
1658
+ # @return [String]
1659
+ attr_accessor :numeric_id
1660
+
1661
+ # A unique reference to this project.
1662
+ # Corresponds to the JSON property `projectReference`
1663
+ # @return [Google::Apis::BigqueryV2::ProjectReference]
1664
+ attr_accessor :project_reference
1665
+
1666
+ def initialize(**args)
1667
+ update!(**args)
1668
+ end
1669
+
1670
+ # Update properties of this object
1671
+ def update!(**args)
1672
+ @friendly_name = args[:friendly_name] if args.key?(:friendly_name)
1673
+ @id = args[:id] if args.key?(:id)
1674
+ @kind = args[:kind] if args.key?(:kind)
1675
+ @numeric_id = args[:numeric_id] if args.key?(:numeric_id)
1676
+ @project_reference = args[:project_reference] if args.key?(:project_reference)
1677
+ end
1678
+ end
1679
+ end
1680
+
1681
+ #
1682
+ class ProjectReference
1683
+ include Google::Apis::Core::Hashable
1684
+
1685
+ # [Required] ID of the project. Can be either the numeric ID or the assigned ID
1686
+ # of the project.
1687
+ # Corresponds to the JSON property `projectId`
1688
+ # @return [String]
1689
+ attr_accessor :project_id
1690
+
1691
+ def initialize(**args)
1692
+ update!(**args)
1693
+ end
1694
+
1695
+ # Update properties of this object
1696
+ def update!(**args)
1697
+ @project_id = args[:project_id] if args.key?(:project_id)
1698
+ end
1699
+ end
1700
+
1701
+ #
1702
+ class QueryRequest
1703
+ include Google::Apis::Core::Hashable
1704
+
1705
+ # [Optional] Specifies the default datasetId and projectId to assume for any
1706
+ # unqualified table names in the query. If not set, all table names in the query
1707
+ # string must be qualified in the format 'datasetId.tableId'.
1708
+ # Corresponds to the JSON property `defaultDataset`
1709
+ # @return [Google::Apis::BigqueryV2::DatasetReference]
1710
+ attr_accessor :default_dataset
1711
+
1712
+ # [Optional] If set to true, BigQuery doesn't run the job. Instead, if the query
1713
+ # is valid, BigQuery returns statistics about the job such as how many bytes
1714
+ # would be processed. If the query is invalid, an error returns. The default
1715
+ # value is false.
1716
+ # Corresponds to the JSON property `dryRun`
1717
+ # @return [Boolean]
1718
+ attr_accessor :dry_run
1719
+ alias_method :dry_run?, :dry_run
1720
+
1721
+ # The resource type of the request.
1722
+ # Corresponds to the JSON property `kind`
1723
+ # @return [String]
1724
+ attr_accessor :kind
1725
+
1726
+ # [Optional] The maximum number of rows of data to return per page of results.
1727
+ # Setting this flag to a small value such as 1000 and then paging through
1728
+ # results might improve reliability when the query result set is large. In
1729
+ # addition to this limit, responses are also limited to 10 MB. By default, there
1730
+ # is no maximum row count, and only the byte limit applies.
1731
+ # Corresponds to the JSON property `maxResults`
1732
+ # @return [Fixnum]
1733
+ attr_accessor :max_results
1734
+
1735
+ # [Deprecated] This property is deprecated.
1736
+ # Corresponds to the JSON property `preserveNulls`
1737
+ # @return [Boolean]
1738
+ attr_accessor :preserve_nulls
1739
+ alias_method :preserve_nulls?, :preserve_nulls
1740
+
1741
+ # [Required] A query string, following the BigQuery query syntax, of the query
1742
+ # to execute. Example: "SELECT count(f1) FROM [myProjectId:myDatasetId.myTableId]
1743
+ # ".
1744
+ # Corresponds to the JSON property `query`
1745
+ # @return [String]
1746
+ attr_accessor :query
1747
+
1748
+ # [Optional] How long to wait for the query to complete, in milliseconds, before
1749
+ # the request times out and returns. Note that this is only a timeout for the
1750
+ # request, not the query. If the query takes longer to run than the timeout
1751
+ # value, the call returns without any results and with the 'jobComplete' flag
1752
+ # set to false. You can call GetQueryResults() to wait for the query to complete
1753
+ # and read the results. The default value is 10000 milliseconds (10 seconds).
1754
+ # Corresponds to the JSON property `timeoutMs`
1755
+ # @return [Fixnum]
1756
+ attr_accessor :timeout_ms
1757
+
1758
+ # [Experimental] Specifies whether to use BigQuery's legacy SQL dialect for this
1759
+ # query. The default value is true. If set to false, the query will use BigQuery'
1760
+ # s updated SQL dialect with improved standards compliance. When using BigQuery'
1761
+ # s updated SQL, the values of allowLargeResults and flattenResults are ignored.
1762
+ # Queries with useLegacySql set to false will be run as if allowLargeResults is
1763
+ # true and flattenResults is false.
1764
+ # Corresponds to the JSON property `useLegacySql`
1765
+ # @return [Boolean]
1766
+ attr_accessor :use_legacy_sql
1767
+ alias_method :use_legacy_sql?, :use_legacy_sql
1768
+
1769
+ # [Optional] Whether to look for the result in the query cache. The query cache
1770
+ # is a best-effort cache that will be flushed whenever tables in the query are
1771
+ # modified. The default value is true.
1772
+ # Corresponds to the JSON property `useQueryCache`
1773
+ # @return [Boolean]
1774
+ attr_accessor :use_query_cache
1775
+ alias_method :use_query_cache?, :use_query_cache
1776
+
1777
+ def initialize(**args)
1778
+ update!(**args)
1779
+ end
1780
+
1781
+ # Update properties of this object
1782
+ def update!(**args)
1783
+ @default_dataset = args[:default_dataset] if args.key?(:default_dataset)
1784
+ @dry_run = args[:dry_run] if args.key?(:dry_run)
1785
+ @kind = args[:kind] if args.key?(:kind)
1786
+ @max_results = args[:max_results] if args.key?(:max_results)
1787
+ @preserve_nulls = args[:preserve_nulls] if args.key?(:preserve_nulls)
1788
+ @query = args[:query] if args.key?(:query)
1789
+ @timeout_ms = args[:timeout_ms] if args.key?(:timeout_ms)
1790
+ @use_legacy_sql = args[:use_legacy_sql] if args.key?(:use_legacy_sql)
1791
+ @use_query_cache = args[:use_query_cache] if args.key?(:use_query_cache)
1792
+ end
1793
+ end
1794
+
1795
+ #
1796
+ class QueryResponse
1797
+ include Google::Apis::Core::Hashable
1798
+
1799
+ # Whether the query result was fetched from the query cache.
1800
+ # Corresponds to the JSON property `cacheHit`
1801
+ # @return [Boolean]
1802
+ attr_accessor :cache_hit
1803
+ alias_method :cache_hit?, :cache_hit
1804
+
1805
+ # [Output-only] All errors and warnings encountered during the running of the
1806
+ # job. Errors here do not necessarily mean that the job has completed or was
1807
+ # unsuccessful.
1808
+ # Corresponds to the JSON property `errors`
1809
+ # @return [Array<Google::Apis::BigqueryV2::ErrorProto>]
1810
+ attr_accessor :errors
1811
+
1812
+ # Whether the query has completed or not. If rows or totalRows are present, this
1813
+ # will always be true. If this is false, totalRows will not be available.
1814
+ # Corresponds to the JSON property `jobComplete`
1815
+ # @return [Boolean]
1816
+ attr_accessor :job_complete
1817
+ alias_method :job_complete?, :job_complete
1818
+
1819
+ # Reference to the Job that was created to run the query. This field will be
1820
+ # present even if the original request timed out, in which case GetQueryResults
1821
+ # can be used to read the results once the query has completed. Since this API
1822
+ # only returns the first page of results, subsequent pages can be fetched via
1823
+ # the same mechanism (GetQueryResults).
1824
+ # Corresponds to the JSON property `jobReference`
1825
+ # @return [Google::Apis::BigqueryV2::JobReference]
1826
+ attr_accessor :job_reference
1827
+
1828
+ # The resource type.
1829
+ # Corresponds to the JSON property `kind`
1830
+ # @return [String]
1831
+ attr_accessor :kind
1832
+
1833
+ # A token used for paging results.
1834
+ # Corresponds to the JSON property `pageToken`
1835
+ # @return [String]
1836
+ attr_accessor :page_token
1837
+
1838
+ # An object with as many results as can be contained within the maximum
1839
+ # permitted reply size. To get any additional rows, you can call GetQueryResults
1840
+ # and specify the jobReference returned above.
1841
+ # Corresponds to the JSON property `rows`
1842
+ # @return [Array<Google::Apis::BigqueryV2::TableRow>]
1843
+ attr_accessor :rows
1844
+
1845
+ # The schema of the results. Present only when the query completes successfully.
1846
+ # Corresponds to the JSON property `schema`
1847
+ # @return [Google::Apis::BigqueryV2::TableSchema]
1848
+ attr_accessor :schema
1849
+
1850
+ # The total number of bytes processed for this query. If this query was a dry
1851
+ # run, this is the number of bytes that would be processed if the query were run.
1852
+ # Corresponds to the JSON property `totalBytesProcessed`
1853
+ # @return [String]
1854
+ attr_accessor :total_bytes_processed
1855
+
1856
+ # The total number of rows in the complete query result set, which can be more
1857
+ # than the number of rows in this single page of results.
1858
+ # Corresponds to the JSON property `totalRows`
1859
+ # @return [String]
1860
+ attr_accessor :total_rows
1861
+
1862
+ def initialize(**args)
1863
+ update!(**args)
1864
+ end
1865
+
1866
+ # Update properties of this object
1867
+ def update!(**args)
1868
+ @cache_hit = args[:cache_hit] if args.key?(:cache_hit)
1869
+ @errors = args[:errors] if args.key?(:errors)
1870
+ @job_complete = args[:job_complete] if args.key?(:job_complete)
1871
+ @job_reference = args[:job_reference] if args.key?(:job_reference)
1872
+ @kind = args[:kind] if args.key?(:kind)
1873
+ @page_token = args[:page_token] if args.key?(:page_token)
1874
+ @rows = args[:rows] if args.key?(:rows)
1875
+ @schema = args[:schema] if args.key?(:schema)
1876
+ @total_bytes_processed = args[:total_bytes_processed] if args.key?(:total_bytes_processed)
1877
+ @total_rows = args[:total_rows] if args.key?(:total_rows)
1878
+ end
1879
+ end
1880
+
1881
+ #
1882
+ class Streamingbuffer
1883
+ include Google::Apis::Core::Hashable
1884
+
1885
+ # [Output-only] A lower-bound estimate of the number of bytes currently in the
1886
+ # streaming buffer.
1887
+ # Corresponds to the JSON property `estimatedBytes`
1888
+ # @return [String]
1889
+ attr_accessor :estimated_bytes
1890
+
1891
+ # [Output-only] A lower-bound estimate of the number of rows currently in the
1892
+ # streaming buffer.
1893
+ # Corresponds to the JSON property `estimatedRows`
1894
+ # @return [String]
1895
+ attr_accessor :estimated_rows
1896
+
1897
+ # [Output-only] Contains the timestamp of the oldest entry in the streaming
1898
+ # buffer, in milliseconds since the epoch, if the streaming buffer is available.
1899
+ # Corresponds to the JSON property `oldestEntryTime`
1900
+ # @return [String]
1901
+ attr_accessor :oldest_entry_time
1902
+
1903
+ def initialize(**args)
1904
+ update!(**args)
1905
+ end
1906
+
1907
+ # Update properties of this object
1908
+ def update!(**args)
1909
+ @estimated_bytes = args[:estimated_bytes] if args.key?(:estimated_bytes)
1910
+ @estimated_rows = args[:estimated_rows] if args.key?(:estimated_rows)
1911
+ @oldest_entry_time = args[:oldest_entry_time] if args.key?(:oldest_entry_time)
1912
+ end
1913
+ end
1914
+
1915
+ #
1916
+ class Table
1917
+ include Google::Apis::Core::Hashable
1918
+
1919
+ # [Output-only] The time when this table was created, in milliseconds since the
1920
+ # epoch.
1921
+ # Corresponds to the JSON property `creationTime`
1922
+ # @return [String]
1923
+ attr_accessor :creation_time
1924
+
1925
+ # [Optional] A user-friendly description of this table.
1926
+ # Corresponds to the JSON property `description`
1927
+ # @return [String]
1928
+ attr_accessor :description
1929
+
1930
+ # [Output-only] A hash of this resource.
1931
+ # Corresponds to the JSON property `etag`
1932
+ # @return [String]
1933
+ attr_accessor :etag
1934
+
1935
+ # [Optional] The time when this table expires, in milliseconds since the epoch.
1936
+ # If not present, the table will persist indefinitely. Expired tables will be
1937
+ # deleted and their storage reclaimed.
1938
+ # Corresponds to the JSON property `expirationTime`
1939
+ # @return [String]
1940
+ attr_accessor :expiration_time
1941
+
1942
+ # [Optional] Describes the data format, location, and other properties of a
1943
+ # table stored outside of BigQuery. By defining these properties, the data
1944
+ # source can then be queried as if it were a standard BigQuery table.
1945
+ # Corresponds to the JSON property `externalDataConfiguration`
1946
+ # @return [Google::Apis::BigqueryV2::ExternalDataConfiguration]
1947
+ attr_accessor :external_data_configuration
1948
+
1949
+ # [Optional] A descriptive name for this table.
1950
+ # Corresponds to the JSON property `friendlyName`
1951
+ # @return [String]
1952
+ attr_accessor :friendly_name
1953
+
1954
+ # [Output-only] An opaque ID uniquely identifying the table.
1955
+ # Corresponds to the JSON property `id`
1956
+ # @return [String]
1957
+ attr_accessor :id
1958
+
1959
+ # [Output-only] The type of the resource.
1960
+ # Corresponds to the JSON property `kind`
1961
+ # @return [String]
1962
+ attr_accessor :kind
1963
+
1964
+ # [Output-only] The time when this table was last modified, in milliseconds
1965
+ # since the epoch.
1966
+ # Corresponds to the JSON property `lastModifiedTime`
1967
+ # @return [String]
1968
+ attr_accessor :last_modified_time
1969
+
1970
+ # [Output-only] The geographic location where the table resides. This value is
1971
+ # inherited from the dataset.
1972
+ # Corresponds to the JSON property `location`
1973
+ # @return [String]
1974
+ attr_accessor :location
1975
+
1976
+ # [Output-only] The size of this table in bytes, excluding any data in the
1977
+ # streaming buffer.
1978
+ # Corresponds to the JSON property `numBytes`
1979
+ # @return [String]
1980
+ attr_accessor :num_bytes
1981
+
1982
+ # [Output-only] The number of rows of data in this table, excluding any data in
1983
+ # the streaming buffer.
1984
+ # Corresponds to the JSON property `numRows`
1985
+ # @return [String]
1986
+ attr_accessor :num_rows
1987
+
1988
+ # [Optional] Describes the schema of this table.
1989
+ # Corresponds to the JSON property `schema`
1990
+ # @return [Google::Apis::BigqueryV2::TableSchema]
1991
+ attr_accessor :schema
1992
+
1993
+ # [Output-only] A URL that can be used to access this resource again.
1994
+ # Corresponds to the JSON property `selfLink`
1995
+ # @return [String]
1996
+ attr_accessor :self_link
1997
+
1998
+ # [Output-only] Contains information regarding this table's streaming buffer, if
1999
+ # one is present. This field will be absent if the table is not being streamed
2000
+ # to or if there is no data in the streaming buffer.
2001
+ # Corresponds to the JSON property `streamingBuffer`
2002
+ # @return [Google::Apis::BigqueryV2::Streamingbuffer]
2003
+ attr_accessor :streaming_buffer
2004
+
2005
+ # [Required] Reference describing the ID of this table.
2006
+ # Corresponds to the JSON property `tableReference`
2007
+ # @return [Google::Apis::BigqueryV2::TableReference]
2008
+ attr_accessor :table_reference
2009
+
2010
+ # [Output-only] Describes the table type. The following values are supported:
2011
+ # TABLE: A normal BigQuery table. VIEW: A virtual table defined by a SQL query.
2012
+ # EXTERNAL: A table that references data stored in an external storage system,
2013
+ # such as Google Cloud Storage. The default value is TABLE.
2014
+ # Corresponds to the JSON property `type`
2015
+ # @return [String]
2016
+ attr_accessor :type
2017
+
2018
+ # [Optional] The view definition.
2019
+ # Corresponds to the JSON property `view`
2020
+ # @return [Google::Apis::BigqueryV2::ViewDefinition]
2021
+ attr_accessor :view
2022
+
2023
+ def initialize(**args)
2024
+ update!(**args)
2025
+ end
2026
+
2027
+ # Update properties of this object
2028
+ def update!(**args)
2029
+ @creation_time = args[:creation_time] if args.key?(:creation_time)
2030
+ @description = args[:description] if args.key?(:description)
2031
+ @etag = args[:etag] if args.key?(:etag)
2032
+ @expiration_time = args[:expiration_time] if args.key?(:expiration_time)
2033
+ @external_data_configuration = args[:external_data_configuration] if args.key?(:external_data_configuration)
2034
+ @friendly_name = args[:friendly_name] if args.key?(:friendly_name)
2035
+ @id = args[:id] if args.key?(:id)
2036
+ @kind = args[:kind] if args.key?(:kind)
2037
+ @last_modified_time = args[:last_modified_time] if args.key?(:last_modified_time)
2038
+ @location = args[:location] if args.key?(:location)
2039
+ @num_bytes = args[:num_bytes] if args.key?(:num_bytes)
2040
+ @num_rows = args[:num_rows] if args.key?(:num_rows)
2041
+ @schema = args[:schema] if args.key?(:schema)
2042
+ @self_link = args[:self_link] if args.key?(:self_link)
2043
+ @streaming_buffer = args[:streaming_buffer] if args.key?(:streaming_buffer)
2044
+ @table_reference = args[:table_reference] if args.key?(:table_reference)
2045
+ @type = args[:type] if args.key?(:type)
2046
+ @view = args[:view] if args.key?(:view)
2047
+ end
2048
+ end
2049
+
2050
+ #
2051
+ class TableCell
2052
+ include Google::Apis::Core::Hashable
2053
+
2054
+ #
2055
+ # Corresponds to the JSON property `v`
2056
+ # @return [Object]
2057
+ attr_accessor :v
2058
+
2059
+ def initialize(**args)
2060
+ update!(**args)
2061
+ end
2062
+
2063
+ # Update properties of this object
2064
+ def update!(**args)
2065
+ @v = args[:v] if args.key?(:v)
2066
+ end
2067
+ end
2068
+
2069
+ #
2070
+ class InsertAllTableDataRequest
2071
+ include Google::Apis::Core::Hashable
2072
+
2073
+ # [Optional] Accept rows that contain values that do not match the schema. The
2074
+ # unknown values are ignored. Default is false, which treats unknown values as
2075
+ # errors.
2076
+ # Corresponds to the JSON property `ignoreUnknownValues`
2077
+ # @return [Boolean]
2078
+ attr_accessor :ignore_unknown_values
2079
+ alias_method :ignore_unknown_values?, :ignore_unknown_values
2080
+
2081
+ # The resource type of the response.
2082
+ # Corresponds to the JSON property `kind`
2083
+ # @return [String]
2084
+ attr_accessor :kind
2085
+
2086
+ # The rows to insert.
2087
+ # Corresponds to the JSON property `rows`
2088
+ # @return [Array<Google::Apis::BigqueryV2::InsertAllTableDataRequest::Row>]
2089
+ attr_accessor :rows
2090
+
2091
+ # [Optional] Insert all valid rows of a request, even if invalid rows exist. The
2092
+ # default value is false, which causes the entire request to fail if any invalid
2093
+ # rows exist.
2094
+ # Corresponds to the JSON property `skipInvalidRows`
2095
+ # @return [Boolean]
2096
+ attr_accessor :skip_invalid_rows
2097
+ alias_method :skip_invalid_rows?, :skip_invalid_rows
2098
+
2099
+ # [Experimental] If specified, treats the destination table as a base template,
2100
+ # and inserts the rows into an instance table named "`destination``
2101
+ # templateSuffix`". BigQuery will manage creation of the instance table, using
2102
+ # the schema of the base template table. See https://cloud.google.com/bigquery/
2103
+ # streaming-data-into-bigquery#template-tables for considerations when working
2104
+ # with templates tables.
2105
+ # Corresponds to the JSON property `templateSuffix`
2106
+ # @return [String]
2107
+ attr_accessor :template_suffix
2108
+
2109
+ def initialize(**args)
2110
+ update!(**args)
2111
+ end
2112
+
2113
+ # Update properties of this object
2114
+ def update!(**args)
2115
+ @ignore_unknown_values = args[:ignore_unknown_values] if args.key?(:ignore_unknown_values)
2116
+ @kind = args[:kind] if args.key?(:kind)
2117
+ @rows = args[:rows] if args.key?(:rows)
2118
+ @skip_invalid_rows = args[:skip_invalid_rows] if args.key?(:skip_invalid_rows)
2119
+ @template_suffix = args[:template_suffix] if args.key?(:template_suffix)
2120
+ end
2121
+
2122
+ #
2123
+ class Row
2124
+ include Google::Apis::Core::Hashable
2125
+
2126
+ # [Optional] A unique ID for each row. BigQuery uses this property to detect
2127
+ # duplicate insertion requests on a best-effort basis.
2128
+ # Corresponds to the JSON property `insertId`
2129
+ # @return [String]
2130
+ attr_accessor :insert_id
2131
+
2132
+ # Represents a single JSON object.
2133
+ # Corresponds to the JSON property `json`
2134
+ # @return [Hash<String,Object>]
2135
+ attr_accessor :json
2136
+
2137
+ def initialize(**args)
2138
+ update!(**args)
2139
+ end
2140
+
2141
+ # Update properties of this object
2142
+ def update!(**args)
2143
+ @insert_id = args[:insert_id] if args.key?(:insert_id)
2144
+ @json = args[:json] if args.key?(:json)
2145
+ end
2146
+ end
2147
+ end
2148
+
2149
+ #
2150
+ class InsertAllTableDataResponse
2151
+ include Google::Apis::Core::Hashable
2152
+
2153
+ # An array of errors for rows that were not inserted.
2154
+ # Corresponds to the JSON property `insertErrors`
2155
+ # @return [Array<Google::Apis::BigqueryV2::InsertAllTableDataResponse::InsertError>]
2156
+ attr_accessor :insert_errors
2157
+
2158
+ # The resource type of the response.
2159
+ # Corresponds to the JSON property `kind`
2160
+ # @return [String]
2161
+ attr_accessor :kind
2162
+
2163
+ def initialize(**args)
2164
+ update!(**args)
2165
+ end
2166
+
2167
+ # Update properties of this object
2168
+ def update!(**args)
2169
+ @insert_errors = args[:insert_errors] if args.key?(:insert_errors)
2170
+ @kind = args[:kind] if args.key?(:kind)
2171
+ end
2172
+
2173
+ #
2174
+ class InsertError
2175
+ include Google::Apis::Core::Hashable
2176
+
2177
+ # Error information for the row indicated by the index property.
2178
+ # Corresponds to the JSON property `errors`
2179
+ # @return [Array<Google::Apis::BigqueryV2::ErrorProto>]
2180
+ attr_accessor :errors
2181
+
2182
+ # The index of the row that error applies to.
2183
+ # Corresponds to the JSON property `index`
2184
+ # @return [Fixnum]
2185
+ attr_accessor :index
2186
+
2187
+ def initialize(**args)
2188
+ update!(**args)
2189
+ end
2190
+
2191
+ # Update properties of this object
2192
+ def update!(**args)
2193
+ @errors = args[:errors] if args.key?(:errors)
2194
+ @index = args[:index] if args.key?(:index)
2195
+ end
2196
+ end
2197
+ end
2198
+
2199
+ #
2200
+ class TableDataList
2201
+ include Google::Apis::Core::Hashable
2202
+
2203
+ # A hash of this page of results.
2204
+ # Corresponds to the JSON property `etag`
2205
+ # @return [String]
2206
+ attr_accessor :etag
2207
+
2208
+ # The resource type of the response.
2209
+ # Corresponds to the JSON property `kind`
2210
+ # @return [String]
2211
+ attr_accessor :kind
2212
+
2213
+ # A token used for paging results. Providing this token instead of the
2214
+ # startIndex parameter can help you retrieve stable results when an underlying
2215
+ # table is changing.
2216
+ # Corresponds to the JSON property `pageToken`
2217
+ # @return [String]
2218
+ attr_accessor :page_token
2219
+
2220
+ # Rows of results.
2221
+ # Corresponds to the JSON property `rows`
2222
+ # @return [Array<Google::Apis::BigqueryV2::TableRow>]
2223
+ attr_accessor :rows
2224
+
2225
+ # The total number of rows in the complete table.
2226
+ # Corresponds to the JSON property `totalRows`
2227
+ # @return [String]
2228
+ attr_accessor :total_rows
2229
+
2230
+ def initialize(**args)
2231
+ update!(**args)
2232
+ end
2233
+
2234
+ # Update properties of this object
2235
+ def update!(**args)
2236
+ @etag = args[:etag] if args.key?(:etag)
2237
+ @kind = args[:kind] if args.key?(:kind)
2238
+ @page_token = args[:page_token] if args.key?(:page_token)
2239
+ @rows = args[:rows] if args.key?(:rows)
2240
+ @total_rows = args[:total_rows] if args.key?(:total_rows)
2241
+ end
2242
+ end
2243
+
2244
+ #
2245
+ class TableFieldSchema
2246
+ include Google::Apis::Core::Hashable
2247
+
2248
+ # [Optional] The field description. The maximum length is 16K characters.
2249
+ # Corresponds to the JSON property `description`
2250
+ # @return [String]
2251
+ attr_accessor :description
2252
+
2253
+ # [Optional] Describes the nested schema fields if the type property is set to
2254
+ # RECORD.
2255
+ # Corresponds to the JSON property `fields`
2256
+ # @return [Array<Google::Apis::BigqueryV2::TableFieldSchema>]
2257
+ attr_accessor :fields
2258
+
2259
+ # [Optional] The field mode. Possible values include NULLABLE, REQUIRED and
2260
+ # REPEATED. The default value is NULLABLE.
2261
+ # Corresponds to the JSON property `mode`
2262
+ # @return [String]
2263
+ attr_accessor :mode
2264
+
2265
+ # [Required] The field name. The name must contain only letters (a-z, A-Z),
2266
+ # numbers (0-9), or underscores (_), and must start with a letter or underscore.
2267
+ # The maximum length is 128 characters.
2268
+ # Corresponds to the JSON property `name`
2269
+ # @return [String]
2270
+ attr_accessor :name
2271
+
2272
+ # [Required] The field data type. Possible values include STRING, INTEGER, FLOAT,
2273
+ # BOOLEAN, TIMESTAMP or RECORD (where RECORD indicates that the field contains
2274
+ # a nested schema).
2275
+ # Corresponds to the JSON property `type`
2276
+ # @return [String]
2277
+ attr_accessor :type
2278
+
2279
+ def initialize(**args)
2280
+ update!(**args)
2281
+ end
2282
+
2283
+ # Update properties of this object
2284
+ def update!(**args)
2285
+ @description = args[:description] if args.key?(:description)
2286
+ @fields = args[:fields] if args.key?(:fields)
2287
+ @mode = args[:mode] if args.key?(:mode)
2288
+ @name = args[:name] if args.key?(:name)
2289
+ @type = args[:type] if args.key?(:type)
2290
+ end
2291
+ end
2292
+
2293
+ #
2294
+ class TableList
2295
+ include Google::Apis::Core::Hashable
2296
+
2297
+ # A hash of this page of results.
2298
+ # Corresponds to the JSON property `etag`
2299
+ # @return [String]
2300
+ attr_accessor :etag
2301
+
2302
+ # The type of list.
2303
+ # Corresponds to the JSON property `kind`
2304
+ # @return [String]
2305
+ attr_accessor :kind
2306
+
2307
+ # A token to request the next page of results.
2308
+ # Corresponds to the JSON property `nextPageToken`
2309
+ # @return [String]
2310
+ attr_accessor :next_page_token
2311
+
2312
+ # Tables in the requested dataset.
2313
+ # Corresponds to the JSON property `tables`
2314
+ # @return [Array<Google::Apis::BigqueryV2::TableList::Table>]
2315
+ attr_accessor :tables
2316
+
2317
+ # The total number of tables in the dataset.
2318
+ # Corresponds to the JSON property `totalItems`
2319
+ # @return [Fixnum]
2320
+ attr_accessor :total_items
2321
+
2322
+ def initialize(**args)
2323
+ update!(**args)
2324
+ end
2325
+
2326
+ # Update properties of this object
2327
+ def update!(**args)
2328
+ @etag = args[:etag] if args.key?(:etag)
2329
+ @kind = args[:kind] if args.key?(:kind)
2330
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
2331
+ @tables = args[:tables] if args.key?(:tables)
2332
+ @total_items = args[:total_items] if args.key?(:total_items)
2333
+ end
2334
+
2335
+ #
2336
+ class Table
2337
+ include Google::Apis::Core::Hashable
2338
+
2339
+ # The user-friendly name for this table.
2340
+ # Corresponds to the JSON property `friendlyName`
2341
+ # @return [String]
2342
+ attr_accessor :friendly_name
2343
+
2344
+ # An opaque ID of the table
2345
+ # Corresponds to the JSON property `id`
2346
+ # @return [String]
2347
+ attr_accessor :id
2348
+
2349
+ # The resource type.
2350
+ # Corresponds to the JSON property `kind`
2351
+ # @return [String]
2352
+ attr_accessor :kind
2353
+
2354
+ # A reference uniquely identifying the table.
2355
+ # Corresponds to the JSON property `tableReference`
2356
+ # @return [Google::Apis::BigqueryV2::TableReference]
2357
+ attr_accessor :table_reference
2358
+
2359
+ # The type of table. Possible values are: TABLE, VIEW.
2360
+ # Corresponds to the JSON property `type`
2361
+ # @return [String]
2362
+ attr_accessor :type
2363
+
2364
+ def initialize(**args)
2365
+ update!(**args)
2366
+ end
2367
+
2368
+ # Update properties of this object
2369
+ def update!(**args)
2370
+ @friendly_name = args[:friendly_name] if args.key?(:friendly_name)
2371
+ @id = args[:id] if args.key?(:id)
2372
+ @kind = args[:kind] if args.key?(:kind)
2373
+ @table_reference = args[:table_reference] if args.key?(:table_reference)
2374
+ @type = args[:type] if args.key?(:type)
2375
+ end
2376
+ end
2377
+ end
2378
+
2379
+ #
2380
+ class TableReference
2381
+ include Google::Apis::Core::Hashable
2382
+
2383
+ # [Required] The ID of the dataset containing this table.
2384
+ # Corresponds to the JSON property `datasetId`
2385
+ # @return [String]
2386
+ attr_accessor :dataset_id
2387
+
2388
+ # [Required] The ID of the project containing this table.
2389
+ # Corresponds to the JSON property `projectId`
2390
+ # @return [String]
2391
+ attr_accessor :project_id
2392
+
2393
+ # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z),
2394
+ # numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
2395
+ # Corresponds to the JSON property `tableId`
2396
+ # @return [String]
2397
+ attr_accessor :table_id
2398
+
2399
+ def initialize(**args)
2400
+ update!(**args)
2401
+ end
2402
+
2403
+ # Update properties of this object
2404
+ def update!(**args)
2405
+ @dataset_id = args[:dataset_id] if args.key?(:dataset_id)
2406
+ @project_id = args[:project_id] if args.key?(:project_id)
2407
+ @table_id = args[:table_id] if args.key?(:table_id)
2408
+ end
2409
+ end
2410
+
2411
+ #
2412
+ class TableRow
2413
+ include Google::Apis::Core::Hashable
2414
+
2415
+ # Represents a single row in the result set, consisting of one or more fields.
2416
+ # Corresponds to the JSON property `f`
2417
+ # @return [Array<Google::Apis::BigqueryV2::TableCell>]
2418
+ attr_accessor :f
2419
+
2420
+ def initialize(**args)
2421
+ update!(**args)
2422
+ end
2423
+
2424
+ # Update properties of this object
2425
+ def update!(**args)
2426
+ @f = args[:f] if args.key?(:f)
2427
+ end
2428
+ end
2429
+
2430
+ #
2431
+ class TableSchema
2432
+ include Google::Apis::Core::Hashable
2433
+
2434
+ # Describes the fields in a table.
2435
+ # Corresponds to the JSON property `fields`
2436
+ # @return [Array<Google::Apis::BigqueryV2::TableFieldSchema>]
2437
+ attr_accessor :fields
2438
+
2439
+ def initialize(**args)
2440
+ update!(**args)
2441
+ end
2442
+
2443
+ # Update properties of this object
2444
+ def update!(**args)
2445
+ @fields = args[:fields] if args.key?(:fields)
2446
+ end
2447
+ end
2448
+
2449
+ #
2450
+ class UserDefinedFunctionResource
2451
+ include Google::Apis::Core::Hashable
2452
+
2453
+ # [Pick one] An inline resource that contains code for a user-defined function (
2454
+ # UDF). Providing a inline code resource is equivalent to providing a URI for a
2455
+ # file containing the same code.
2456
+ # Corresponds to the JSON property `inlineCode`
2457
+ # @return [String]
2458
+ attr_accessor :inline_code
2459
+
2460
+ # [Pick one] A code resource to load from a Google Cloud Storage URI (gs://
2461
+ # bucket/path).
2462
+ # Corresponds to the JSON property `resourceUri`
2463
+ # @return [String]
2464
+ attr_accessor :resource_uri
2465
+
2466
+ def initialize(**args)
2467
+ update!(**args)
2468
+ end
2469
+
2470
+ # Update properties of this object
2471
+ def update!(**args)
2472
+ @inline_code = args[:inline_code] if args.key?(:inline_code)
2473
+ @resource_uri = args[:resource_uri] if args.key?(:resource_uri)
2474
+ end
2475
+ end
2476
+
2477
+ #
2478
+ class ViewDefinition
2479
+ include Google::Apis::Core::Hashable
2480
+
2481
+ # [Required] A query that BigQuery executes when the view is referenced.
2482
+ # Corresponds to the JSON property `query`
2483
+ # @return [String]
2484
+ attr_accessor :query
2485
+
2486
+ # [Experimental] Describes user-defined function resources used in the query.
2487
+ # Corresponds to the JSON property `userDefinedFunctionResources`
2488
+ # @return [Array<Google::Apis::BigqueryV2::UserDefinedFunctionResource>]
2489
+ attr_accessor :user_defined_function_resources
2490
+
2491
+ def initialize(**args)
2492
+ update!(**args)
2493
+ end
2494
+
2495
+ # Update properties of this object
2496
+ def update!(**args)
2497
+ @query = args[:query] if args.key?(:query)
2498
+ @user_defined_function_resources = args[:user_defined_function_resources] if args.key?(:user_defined_function_resources)
2499
+ end
2500
+ end
2501
+ end
2502
+ end
2503
+ end