Skip to content

Commit 4fe25ef

Browse files
authored
chore(BigQuery): Add documentation for accessPolicyVersion, updateMode, and datasetView to getDataset and patchDataset methods (#8684)
1 parent 704809e commit 4fe25ef

2 files changed

Lines changed: 63 additions & 6 deletions

File tree

BigQuery/src/BigQueryClient.php

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -659,9 +659,18 @@ function (array $dataset) {
659659
* @param array $options [optional] {
660660
* Configuration options.
661661
*
662+
* @type int $accessPolicyVersion Optional. Access policy schema version. Valid values are 0, 1, and 3. Requests
663+
* specifying an invalid value will be rejected. Requests for conditional access policy binding in datasets
664+
* must specify version 3. Dataset with no conditional role bindings in access policy may specify any valid
665+
* value or leave the field unset. This field will be mapped to [IAM Policy version]
666+
* (https://cloud.google.com/iam/docs/policies#versions) and will be used to fetch policy from IAM. If
667+
* unset or if 0 or 1 value is used for dataset with conditional bindings, access entry with condition will
668+
* have role string appended by 'withcond' string followed by a hash value. For example : { "access": [ {
669+
* "role": "roles/bigquery.dataViewer_with_conditionalbinding_7a34awqsda", "userByEmail":
670+
* "user@example.com", } ] } Please refer https://cloud.google.com/iam/docs/troubleshooting-withcond for
671+
* more details.
662672
* @type array $metadata The available options for metadata are outlined
663-
* at the [Dataset Resource API docs](
664-
* https://cloud.google.com/bigquery/docs/reference/rest/v2/datasets)
673+
* at the [Dataset Resource API docs](https://cloud.google.com/bigquery/docs/reference/rest/v2/datasets)
665674
* }
666675
* @return Dataset
667676
*/

BigQuery/src/Dataset.php

Lines changed: 52 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,23 @@ public function delete(array $options = [])
161161
*
162162
* @param array $metadata The available options for metadata are outlined
163163
* at the [Dataset Resource API docs](https://cloud.google.com/bigquery/docs/reference/rest/v2/datasets)
164-
* @param array $options [optional] Configuration options.
164+
* @param array $options [optional] {
165+
* Configuration options.
166+
*
167+
* @type int $accessPolicyVersion Optional. Access policy schema version. Valid values are 0, 1, and 3. Requests
168+
* specifying an invalid value will be rejected. Requests for conditional access policy binding in datasets
169+
* must specify version 3. Dataset with no conditional role bindings in access policy may specify any valid
170+
* value or leave the field unset. This field will be mapped to [IAM Policy version]
171+
* (https://cloud.google.com/iam/docs/policies#versions) and will be used to fetch policy from IAM. If
172+
* unset or if 0 or 1 value is used for dataset with conditional bindings, access entry with condition will
173+
* have role string appended by 'withcond' string followed by a hash value. For example : { "access": [ {
174+
* "role": "roles/bigquery.dataViewer_with_conditionalbinding_7a34awqsda", "userByEmail":
175+
* "user@example.com", } ] } Please refer https://cloud.google.com/iam/docs/troubleshooting-withcond for
176+
* more details.
177+
* @type string $updateMode Optional. Specifies the fields of dataset that update/patch operation is targeting.
178+
* Acceptable values include "UPDATE_MODE_UNSPECIFIED", "UPDATE_METADATA", "UPDATE_ACL", "UPDATE_FULL".
179+
* By default, both metadata and ACL fields are updated.
180+
* }
165181
*/
166182
public function update(array $metadata, array $options = [])
167183
{
@@ -532,8 +548,24 @@ public function createRoutine($id, array $metadata, array $options = [])
532548
*
533549
* @see https://cloud.google.com/bigquery/docs/reference/rest/v2/datasets Datasets resource documentation.
534550
*
535-
* @param array $options [optional] Configuration options.
536-
* @return array
551+
* @param array $options [optional] {
552+
* Configuration options.
553+
*
554+
* @type int $accessPolicyVersion Optional. Access policy schema version. Valid values are 0, 1, and 3. Requests
555+
* specifying an invalid value will be rejected. Requests for conditional access policy binding in datasets
556+
* must specify version 3. Dataset with no conditional role bindings in access policy may specify any valid
557+
* value or leave the field unset. This field will be mapped to [IAM Policy version]
558+
* (https://cloud.google.com/iam/docs/policies#versions) and will be used to fetch policy from IAM. If
559+
* unset or if 0 or 1 value is used for dataset with conditional bindings, access entry with condition will
560+
* have role string appended by 'withcond' string followed by a hash value. For example : { "access": [ {
561+
* "role": "roles/bigquery.dataViewer_with_conditionalbinding_7a34awqsda", "userByEmail":
562+
* "user@example.com", } ] } Please refer https://cloud.google.com/iam/docs/troubleshooting-withcond for
563+
* more details.
564+
* @type string $datasetView Optional. Specifies the view that determines which dataset information is returned.
565+
* Acceptable values include "DATASET_VIEW_UNSPECIFIED", "METADATA", "ACL", "FULL". By default, metadata
566+
* and ACL information are returned.
567+
* }
568+
* @return array.
537569
*/
538570
public function info(array $options = [])
539571
{
@@ -556,7 +588,23 @@ public function info(array $options = [])
556588
*
557589
* @see https://cloud.google.com/bigquery/docs/reference/rest/v2/datasets/get Datasets get API documentation.
558590
*
559-
* @param array $options [optional] Configuration options.
591+
* @param array $options [optional] {
592+
* Configuration options.
593+
*
594+
* @type int $accessPolicyVersion Optional. Access policy schema version. Valid values are 0, 1, and 3. Requests
595+
* specifying an invalid value will be rejected. Requests for conditional access policy binding in datasets
596+
* must specify version 3. Dataset with no conditional role bindings in access policy may specify any valid
597+
* value or leave the field unset. This field will be mapped to [IAM Policy version]
598+
* (https://cloud.google.com/iam/docs/policies#versions) and will be used to fetch policy from IAM. If
599+
* unset or if 0 or 1 value is used for dataset with conditional bindings, access entry with condition will
600+
* have role string appended by 'withcond' string followed by a hash value. For example : { "access": [ {
601+
* "role": "roles/bigquery.dataViewer_with_conditionalbinding_7a34awqsda", "userByEmail":
602+
* "user@example.com", } ] } Please refer https://cloud.google.com/iam/docs/troubleshooting-withcond for
603+
* more details.
604+
* @type string $datasetView Optional. Specifies the view that determines which dataset information is returned.
605+
* Acceptable values include "DATASET_VIEW_UNSPECIFIED", "METADATA", "ACL", "FULL". By default, metadata
606+
* and ACL information are returned.
607+
* }
560608
* @return array
561609
*/
562610
public function reload(array $options = [])

0 commit comments

Comments
 (0)