1 | <?php
|
---|
2 | /*
|
---|
3 | * Copyright 2014 Google Inc.
|
---|
4 | *
|
---|
5 | * Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
---|
6 | * use this file except in compliance with the License. You may obtain a copy of
|
---|
7 | * the License at
|
---|
8 | *
|
---|
9 | * http://www.apache.org/licenses/LICENSE-2.0
|
---|
10 | *
|
---|
11 | * Unless required by applicable law or agreed to in writing, software
|
---|
12 | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
---|
13 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
---|
14 | * License for the specific language governing permissions and limitations under
|
---|
15 | * the License.
|
---|
16 | */
|
---|
17 |
|
---|
18 | namespace Google\Service\SecurityCommandCenter\Resource;
|
---|
19 |
|
---|
20 | use Google\Service\SecurityCommandCenter\GoogleCloudSecuritycenterV1BigQueryExport;
|
---|
21 | use Google\Service\SecurityCommandCenter\ListBigQueryExportsResponse;
|
---|
22 | use Google\Service\SecurityCommandCenter\SecuritycenterEmpty;
|
---|
23 |
|
---|
24 | /**
|
---|
25 | * The "bigQueryExports" collection of methods.
|
---|
26 | * Typical usage is:
|
---|
27 | * <code>
|
---|
28 | * $securitycenterService = new Google\Service\SecurityCommandCenter(...);
|
---|
29 | * $bigQueryExports = $securitycenterService->organizations_bigQueryExports;
|
---|
30 | * </code>
|
---|
31 | */
|
---|
32 | class OrganizationsBigQueryExports extends \Google\Service\Resource
|
---|
33 | {
|
---|
34 | /**
|
---|
35 | * Creates a BigQuery export. (bigQueryExports.create)
|
---|
36 | *
|
---|
37 | * @param string $parent Required. The name of the parent resource of the new
|
---|
38 | * BigQuery export. Its format is `organizations/[organization_id]`,
|
---|
39 | * `folders/[folder_id]`, or `projects/[project_id]`.
|
---|
40 | * @param GoogleCloudSecuritycenterV1BigQueryExport $postBody
|
---|
41 | * @param array $optParams Optional parameters.
|
---|
42 | *
|
---|
43 | * @opt_param string bigQueryExportId Required. Unique identifier provided by
|
---|
44 | * the client within the parent scope. It must consist of only lowercase
|
---|
45 | * letters, numbers, and hyphens, must start with a letter, must end with either
|
---|
46 | * a letter or a number, and must be 63 characters or less.
|
---|
47 | * @return GoogleCloudSecuritycenterV1BigQueryExport
|
---|
48 | * @throws \Google\Service\Exception
|
---|
49 | */
|
---|
50 | public function create($parent, GoogleCloudSecuritycenterV1BigQueryExport $postBody, $optParams = [])
|
---|
51 | {
|
---|
52 | $params = ['parent' => $parent, 'postBody' => $postBody];
|
---|
53 | $params = array_merge($params, $optParams);
|
---|
54 | return $this->call('create', [$params], GoogleCloudSecuritycenterV1BigQueryExport::class);
|
---|
55 | }
|
---|
56 | /**
|
---|
57 | * Deletes an existing BigQuery export. (bigQueryExports.delete)
|
---|
58 | *
|
---|
59 | * @param string $name Required. The name of the BigQuery export to delete. Its
|
---|
60 | * format is `organizations/{organization}/bigQueryExports/{export_id}`,
|
---|
61 | * `folders/{folder}/bigQueryExports/{export_id}`, or
|
---|
62 | * `projects/{project}/bigQueryExports/{export_id}`
|
---|
63 | * @param array $optParams Optional parameters.
|
---|
64 | * @return SecuritycenterEmpty
|
---|
65 | * @throws \Google\Service\Exception
|
---|
66 | */
|
---|
67 | public function delete($name, $optParams = [])
|
---|
68 | {
|
---|
69 | $params = ['name' => $name];
|
---|
70 | $params = array_merge($params, $optParams);
|
---|
71 | return $this->call('delete', [$params], SecuritycenterEmpty::class);
|
---|
72 | }
|
---|
73 | /**
|
---|
74 | * Gets a BigQuery export. (bigQueryExports.get)
|
---|
75 | *
|
---|
76 | * @param string $name Required. Name of the BigQuery export to retrieve. Its
|
---|
77 | * format is `organizations/{organization}/bigQueryExports/{export_id}`,
|
---|
78 | * `folders/{folder}/bigQueryExports/{export_id}`, or
|
---|
79 | * `projects/{project}/bigQueryExports/{export_id}`
|
---|
80 | * @param array $optParams Optional parameters.
|
---|
81 | * @return GoogleCloudSecuritycenterV1BigQueryExport
|
---|
82 | * @throws \Google\Service\Exception
|
---|
83 | */
|
---|
84 | public function get($name, $optParams = [])
|
---|
85 | {
|
---|
86 | $params = ['name' => $name];
|
---|
87 | $params = array_merge($params, $optParams);
|
---|
88 | return $this->call('get', [$params], GoogleCloudSecuritycenterV1BigQueryExport::class);
|
---|
89 | }
|
---|
90 | /**
|
---|
91 | * Lists BigQuery exports. Note that when requesting BigQuery exports at a given
|
---|
92 | * level all exports under that level are also returned e.g. if requesting
|
---|
93 | * BigQuery exports under a folder, then all BigQuery exports immediately under
|
---|
94 | * the folder plus the ones created under the projects within the folder are
|
---|
95 | * returned. (bigQueryExports.listOrganizationsBigQueryExports)
|
---|
96 | *
|
---|
97 | * @param string $parent Required. The parent, which owns the collection of
|
---|
98 | * BigQuery exports. Its format is `organizations/[organization_id]`,
|
---|
99 | * `folders/[folder_id]`, `projects/[project_id]`.
|
---|
100 | * @param array $optParams Optional parameters.
|
---|
101 | *
|
---|
102 | * @opt_param int pageSize The maximum number of configs to return. The service
|
---|
103 | * may return fewer than this value. If unspecified, at most 10 configs will be
|
---|
104 | * returned. The maximum value is 1000; values above 1000 will be coerced to
|
---|
105 | * 1000.
|
---|
106 | * @opt_param string pageToken A page token, received from a previous
|
---|
107 | * `ListBigQueryExports` call. Provide this to retrieve the subsequent page.
|
---|
108 | * When paginating, all other parameters provided to `ListBigQueryExports` must
|
---|
109 | * match the call that provided the page token.
|
---|
110 | * @return ListBigQueryExportsResponse
|
---|
111 | * @throws \Google\Service\Exception
|
---|
112 | */
|
---|
113 | public function listOrganizationsBigQueryExports($parent, $optParams = [])
|
---|
114 | {
|
---|
115 | $params = ['parent' => $parent];
|
---|
116 | $params = array_merge($params, $optParams);
|
---|
117 | return $this->call('list', [$params], ListBigQueryExportsResponse::class);
|
---|
118 | }
|
---|
119 | /**
|
---|
120 | * Updates a BigQuery export. (bigQueryExports.patch)
|
---|
121 | *
|
---|
122 | * @param string $name The relative resource name of this export. See:
|
---|
123 | * https://cloud.google.com/apis/design/resource_names#relative_resource_name.
|
---|
124 | * Example format: "organizations/{organization_id}/bigQueryExports/{export_id}"
|
---|
125 | * Example format: "folders/{folder_id}/bigQueryExports/{export_id}" Example
|
---|
126 | * format: "projects/{project_id}/bigQueryExports/{export_id}" This field is
|
---|
127 | * provided in responses, and is ignored when provided in create requests.
|
---|
128 | * @param GoogleCloudSecuritycenterV1BigQueryExport $postBody
|
---|
129 | * @param array $optParams Optional parameters.
|
---|
130 | *
|
---|
131 | * @opt_param string updateMask The list of fields to be updated. If empty all
|
---|
132 | * mutable fields will be updated.
|
---|
133 | * @return GoogleCloudSecuritycenterV1BigQueryExport
|
---|
134 | * @throws \Google\Service\Exception
|
---|
135 | */
|
---|
136 | public function patch($name, GoogleCloudSecuritycenterV1BigQueryExport $postBody, $optParams = [])
|
---|
137 | {
|
---|
138 | $params = ['name' => $name, 'postBody' => $postBody];
|
---|
139 | $params = array_merge($params, $optParams);
|
---|
140 | return $this->call('patch', [$params], GoogleCloudSecuritycenterV1BigQueryExport::class);
|
---|
141 | }
|
---|
142 | }
|
---|
143 |
|
---|
144 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
145 | class_alias(OrganizationsBigQueryExports::class, 'Google_Service_SecurityCommandCenter_Resource_OrganizationsBigQueryExports');
|
---|