| OLD | NEW |
| 1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 | 2 |
| 3 library googleapis_beta.cloudresourcemanager.v1beta1; | 3 library googleapis_beta.cloudresourcemanager.v1beta1; |
| 4 | 4 |
| 5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
| 6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
| 7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
| 8 | 8 |
| 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
| 10 import 'package:http/http.dart' as http; | 10 import 'package:http/http.dart' as http; |
| 11 | 11 |
| 12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show | 12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' |
| 13 ApiRequestError, DetailedApiRequestError; | 13 show ApiRequestError, DetailedApiRequestError; |
| 14 | 14 |
| 15 const core.String USER_AGENT = 'dart-api-client cloudresourcemanager/v1beta1'; | 15 const core.String USER_AGENT = 'dart-api-client cloudresourcemanager/v1beta1'; |
| 16 | 16 |
| 17 /** | 17 /// The Google Cloud Resource Manager API provides methods for creating, |
| 18 * The Google Cloud Resource Manager API provides methods for creating, reading, | 18 /// reading, and updating project metadata. |
| 19 * and updating project metadata. | |
| 20 */ | |
| 21 class CloudresourcemanagerApi { | 19 class CloudresourcemanagerApi { |
| 22 /** View and manage your data across Google Cloud Platform services */ | 20 /// View and manage your data across Google Cloud Platform services |
| 23 static const CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platf
orm"; | 21 static const CloudPlatformScope = |
| 22 "https://www.googleapis.com/auth/cloud-platform"; |
| 24 | 23 |
| 25 /** View your data across Google Cloud Platform services */ | 24 /// View your data across Google Cloud Platform services |
| 26 static const CloudPlatformReadOnlyScope = "https://www.googleapis.com/auth/clo
ud-platform.read-only"; | 25 static const CloudPlatformReadOnlyScope = |
| 27 | 26 "https://www.googleapis.com/auth/cloud-platform.read-only"; |
| 28 | 27 |
| 29 final commons.ApiRequester _requester; | 28 final commons.ApiRequester _requester; |
| 30 | 29 |
| 31 OrganizationsResourceApi get organizations => new OrganizationsResourceApi(_re
quester); | 30 OrganizationsResourceApi get organizations => |
| 31 new OrganizationsResourceApi(_requester); |
| 32 ProjectsResourceApi get projects => new ProjectsResourceApi(_requester); | 32 ProjectsResourceApi get projects => new ProjectsResourceApi(_requester); |
| 33 | 33 |
| 34 CloudresourcemanagerApi(http.Client client, {core.String rootUrl: "https://clo
udresourcemanager.googleapis.com/", core.String servicePath: ""}) : | 34 CloudresourcemanagerApi(http.Client client, |
| 35 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); | 35 {core.String rootUrl: "https://cloudresourcemanager.googleapis.com/", |
| 36 core.String servicePath: ""}) |
| 37 : _requester = |
| 38 new commons.ApiRequester(client, rootUrl, servicePath, USER_AGENT); |
| 36 } | 39 } |
| 37 | 40 |
| 38 | |
| 39 class OrganizationsResourceApi { | 41 class OrganizationsResourceApi { |
| 40 final commons.ApiRequester _requester; | 42 final commons.ApiRequester _requester; |
| 41 | 43 |
| 42 OrganizationsResourceApi(commons.ApiRequester client) : | 44 OrganizationsResourceApi(commons.ApiRequester client) : _requester = client; |
| 43 _requester = client; | |
| 44 | 45 |
| 45 /** | 46 /// Fetches an Organization resource identified by the specified resource |
| 46 * Fetches an Organization resource identified by the specified resource name. | 47 /// name. |
| 47 * | 48 /// |
| 48 * Request parameters: | 49 /// Request parameters: |
| 49 * | 50 /// |
| 50 * [name] - The resource name of the Organization to fetch, e.g. | 51 /// [name] - The resource name of the Organization to fetch, e.g. |
| 51 * "organizations/1234". | 52 /// "organizations/1234". |
| 52 * Value must have pattern "^organizations/[^/]+$". | 53 /// Value must have pattern "^organizations/[^/]+$". |
| 53 * | 54 /// |
| 54 * [organizationId] - The id of the Organization resource to fetch. | 55 /// [organizationId] - The id of the Organization resource to fetch. |
| 55 * This field is deprecated and will be removed in v1. Use name instead. | 56 /// This field is deprecated and will be removed in v1. Use name instead. |
| 56 * | 57 /// |
| 57 * Completes with a [Organization]. | 58 /// Completes with a [Organization]. |
| 58 * | 59 /// |
| 59 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 60 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 60 * error. | 61 /// an error. |
| 61 * | 62 /// |
| 62 * If the used [http.Client] completes with an error when making a REST call, | 63 /// If the used [http.Client] completes with an error when making a REST |
| 63 * this method will complete with the same error. | 64 /// call, this method will complete with the same error. |
| 64 */ | 65 async.Future<Organization> get(core.String name, |
| 65 async.Future<Organization> get(core.String name, {core.String organizationId})
{ | 66 {core.String organizationId}) { |
| 66 var _url = null; | 67 var _url = null; |
| 67 var _queryParams = new core.Map(); | 68 var _queryParams = new core.Map(); |
| 68 var _uploadMedia = null; | 69 var _uploadMedia = null; |
| 69 var _uploadOptions = null; | 70 var _uploadOptions = null; |
| 70 var _downloadOptions = commons.DownloadOptions.Metadata; | 71 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 71 var _body = null; | 72 var _body = null; |
| 72 | 73 |
| 73 if (name == null) { | 74 if (name == null) { |
| 74 throw new core.ArgumentError("Parameter name is required."); | 75 throw new core.ArgumentError("Parameter name is required."); |
| 75 } | 76 } |
| 76 if (organizationId != null) { | 77 if (organizationId != null) { |
| 77 _queryParams["organizationId"] = [organizationId]; | 78 _queryParams["organizationId"] = [organizationId]; |
| 78 } | 79 } |
| 79 | 80 |
| 80 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$name'); | 81 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 81 | 82 |
| 82 var _response = _requester.request(_url, | 83 var _response = _requester.request(_url, "GET", |
| 83 "GET", | 84 body: _body, |
| 84 body: _body, | 85 queryParams: _queryParams, |
| 85 queryParams: _queryParams, | 86 uploadOptions: _uploadOptions, |
| 86 uploadOptions: _uploadOptions, | 87 uploadMedia: _uploadMedia, |
| 87 uploadMedia: _uploadMedia, | 88 downloadOptions: _downloadOptions); |
| 88 downloadOptions: _downloadOptions); | |
| 89 return _response.then((data) => new Organization.fromJson(data)); | 89 return _response.then((data) => new Organization.fromJson(data)); |
| 90 } | 90 } |
| 91 | 91 |
| 92 /** | 92 /// Gets the access control policy for an Organization resource. May be empty |
| 93 * Gets the access control policy for an Organization resource. May be empty | 93 /// if no such policy or resource exists. The `resource` field should be the |
| 94 * if no such policy or resource exists. The `resource` field should be the | 94 /// organization's resource name, e.g. "organizations/123". |
| 95 * organization's resource name, e.g. "organizations/123". | 95 /// |
| 96 * | 96 /// [request] - The metadata request object. |
| 97 * [request] - The metadata request object. | 97 /// |
| 98 * | 98 /// Request parameters: |
| 99 * Request parameters: | 99 /// |
| 100 * | 100 /// [resource] - REQUIRED: The resource for which the policy is being |
| 101 * [resource] - REQUIRED: The resource for which the policy is being | 101 /// requested. |
| 102 * requested. | 102 /// See the operation documentation for the appropriate value for this field. |
| 103 * See the operation documentation for the appropriate value for this field. | 103 /// Value must have pattern "^organizations/[^/]+$". |
| 104 * Value must have pattern "^organizations/[^/]+$". | 104 /// |
| 105 * | 105 /// Completes with a [Policy]. |
| 106 * Completes with a [Policy]. | 106 /// |
| 107 * | 107 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 108 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 108 /// an error. |
| 109 * error. | 109 /// |
| 110 * | 110 /// If the used [http.Client] completes with an error when making a REST |
| 111 * If the used [http.Client] completes with an error when making a REST call, | 111 /// call, this method will complete with the same error. |
| 112 * this method will complete with the same error. | 112 async.Future<Policy> getIamPolicy( |
| 113 */ | 113 GetIamPolicyRequest request, core.String resource) { |
| 114 async.Future<Policy> getIamPolicy(GetIamPolicyRequest request, core.String res
ource) { | |
| 115 var _url = null; | 114 var _url = null; |
| 116 var _queryParams = new core.Map(); | 115 var _queryParams = new core.Map(); |
| 117 var _uploadMedia = null; | 116 var _uploadMedia = null; |
| 118 var _uploadOptions = null; | 117 var _uploadOptions = null; |
| 119 var _downloadOptions = commons.DownloadOptions.Metadata; | 118 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 120 var _body = null; | 119 var _body = null; |
| 121 | 120 |
| 122 if (request != null) { | 121 if (request != null) { |
| 123 _body = convert.JSON.encode((request).toJson()); | 122 _body = convert.JSON.encode((request).toJson()); |
| 124 } | 123 } |
| 125 if (resource == null) { | 124 if (resource == null) { |
| 126 throw new core.ArgumentError("Parameter resource is required."); | 125 throw new core.ArgumentError("Parameter resource is required."); |
| 127 } | 126 } |
| 128 | 127 |
| 129 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':g
etIamPolicy'; | 128 _url = 'v1beta1/' + |
| 129 commons.Escaper.ecapeVariableReserved('$resource') + |
| 130 ':getIamPolicy'; |
| 130 | 131 |
| 131 var _response = _requester.request(_url, | 132 var _response = _requester.request(_url, "POST", |
| 132 "POST", | 133 body: _body, |
| 133 body: _body, | 134 queryParams: _queryParams, |
| 134 queryParams: _queryParams, | 135 uploadOptions: _uploadOptions, |
| 135 uploadOptions: _uploadOptions, | 136 uploadMedia: _uploadMedia, |
| 136 uploadMedia: _uploadMedia, | 137 downloadOptions: _downloadOptions); |
| 137 downloadOptions: _downloadOptions); | |
| 138 return _response.then((data) => new Policy.fromJson(data)); | 138 return _response.then((data) => new Policy.fromJson(data)); |
| 139 } | 139 } |
| 140 | 140 |
| 141 /** | 141 /// Lists Organization resources that are visible to the user and satisfy |
| 142 * Lists Organization resources that are visible to the user and satisfy | 142 /// the specified filter. This method returns Organizations in an unspecified |
| 143 * the specified filter. This method returns Organizations in an unspecified | 143 /// order. New Organizations do not necessarily appear at the end of the |
| 144 * order. New Organizations do not necessarily appear at the end of the list. | 144 /// list. |
| 145 * | 145 /// |
| 146 * Request parameters: | 146 /// Request parameters: |
| 147 * | 147 /// |
| 148 * [filter] - An optional query string used to filter the Organizations to | 148 /// [pageToken] - A pagination token returned from a previous call to |
| 149 * return in | 149 /// `ListOrganizations` |
| 150 * the response. Filter rules are case-insensitive. | 150 /// that indicates from where listing should continue. |
| 151 * | 151 /// This field is optional. |
| 152 * | 152 /// |
| 153 * Organizations may be filtered by `owner.directoryCustomerId` or by | 153 /// [pageSize] - The maximum number of Organizations to return in the |
| 154 * `domain`, where the domain is a Google for Work domain, for example: | 154 /// response. |
| 155 * | 155 /// This field is optional. |
| 156 * |Filter|Description| | 156 /// |
| 157 * |------|-----------| | 157 /// [filter] - An optional query string used to filter the Organizations to |
| 158 * |owner.directorycustomerid:123456789|Organizations with | 158 /// return in |
| 159 * `owner.directory_customer_id` equal to `123456789`.| | 159 /// the response. Filter rules are case-insensitive. |
| 160 * |domain:google.com|Organizations corresponding to the domain `google.com`.| | 160 /// |
| 161 * | 161 /// |
| 162 * This field is optional. | 162 /// Organizations may be filtered by `owner.directoryCustomerId` or by |
| 163 * | 163 /// `domain`, where the domain is a Google for Work domain, for example: |
| 164 * [pageToken] - A pagination token returned from a previous call to | 164 /// |
| 165 * `ListOrganizations` | 165 /// |Filter|Description| |
| 166 * that indicates from where listing should continue. | 166 /// |------|-----------| |
| 167 * This field is optional. | 167 /// |owner.directorycustomerid:123456789|Organizations with |
| 168 * | 168 /// `owner.directory_customer_id` equal to `123456789`.| |
| 169 * [pageSize] - The maximum number of Organizations to return in the response. | 169 /// |domain:google.com|Organizations corresponding to the domain |
| 170 * This field is optional. | 170 /// `google.com`.| |
| 171 * | 171 /// |
| 172 * Completes with a [ListOrganizationsResponse]. | 172 /// This field is optional. |
| 173 * | 173 /// |
| 174 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 174 /// Completes with a [ListOrganizationsResponse]. |
| 175 * error. | 175 /// |
| 176 * | 176 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 177 * If the used [http.Client] completes with an error when making a REST call, | 177 /// an error. |
| 178 * this method will complete with the same error. | 178 /// |
| 179 */ | 179 /// If the used [http.Client] completes with an error when making a REST |
| 180 async.Future<ListOrganizationsResponse> list({core.String filter, core.String
pageToken, core.int pageSize}) { | 180 /// call, this method will complete with the same error. |
| 181 async.Future<ListOrganizationsResponse> list( |
| 182 {core.String pageToken, core.int pageSize, core.String filter}) { |
| 181 var _url = null; | 183 var _url = null; |
| 182 var _queryParams = new core.Map(); | 184 var _queryParams = new core.Map(); |
| 183 var _uploadMedia = null; | 185 var _uploadMedia = null; |
| 184 var _uploadOptions = null; | 186 var _uploadOptions = null; |
| 185 var _downloadOptions = commons.DownloadOptions.Metadata; | 187 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 186 var _body = null; | 188 var _body = null; |
| 187 | 189 |
| 188 if (filter != null) { | |
| 189 _queryParams["filter"] = [filter]; | |
| 190 } | |
| 191 if (pageToken != null) { | 190 if (pageToken != null) { |
| 192 _queryParams["pageToken"] = [pageToken]; | 191 _queryParams["pageToken"] = [pageToken]; |
| 193 } | 192 } |
| 194 if (pageSize != null) { | 193 if (pageSize != null) { |
| 195 _queryParams["pageSize"] = ["${pageSize}"]; | 194 _queryParams["pageSize"] = ["${pageSize}"]; |
| 196 } | 195 } |
| 196 if (filter != null) { |
| 197 _queryParams["filter"] = [filter]; |
| 198 } |
| 197 | 199 |
| 198 _url = 'v1beta1/organizations'; | 200 _url = 'v1beta1/organizations'; |
| 199 | 201 |
| 200 var _response = _requester.request(_url, | 202 var _response = _requester.request(_url, "GET", |
| 201 "GET", | 203 body: _body, |
| 202 body: _body, | 204 queryParams: _queryParams, |
| 203 queryParams: _queryParams, | 205 uploadOptions: _uploadOptions, |
| 204 uploadOptions: _uploadOptions, | 206 uploadMedia: _uploadMedia, |
| 205 uploadMedia: _uploadMedia, | 207 downloadOptions: _downloadOptions); |
| 206 downloadOptions: _downloadOptions); | 208 return _response |
| 207 return _response.then((data) => new ListOrganizationsResponse.fromJson(data)
); | 209 .then((data) => new ListOrganizationsResponse.fromJson(data)); |
| 208 } | 210 } |
| 209 | 211 |
| 210 /** | 212 /// Sets the access control policy on an Organization resource. Replaces any |
| 211 * Sets the access control policy on an Organization resource. Replaces any | 213 /// existing policy. The `resource` field should be the organization's |
| 212 * existing policy. The `resource` field should be the organization's resource | 214 /// resource |
| 213 * name, e.g. "organizations/123". | 215 /// name, e.g. "organizations/123". |
| 214 * | 216 /// |
| 215 * [request] - The metadata request object. | 217 /// [request] - The metadata request object. |
| 216 * | 218 /// |
| 217 * Request parameters: | 219 /// Request parameters: |
| 218 * | 220 /// |
| 219 * [resource] - REQUIRED: The resource for which the policy is being | 221 /// [resource] - REQUIRED: The resource for which the policy is being |
| 220 * specified. | 222 /// specified. |
| 221 * See the operation documentation for the appropriate value for this field. | 223 /// See the operation documentation for the appropriate value for this field. |
| 222 * Value must have pattern "^organizations/[^/]+$". | 224 /// Value must have pattern "^organizations/[^/]+$". |
| 223 * | 225 /// |
| 224 * Completes with a [Policy]. | 226 /// Completes with a [Policy]. |
| 225 * | 227 /// |
| 226 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 228 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 227 * error. | 229 /// an error. |
| 228 * | 230 /// |
| 229 * If the used [http.Client] completes with an error when making a REST call, | 231 /// If the used [http.Client] completes with an error when making a REST |
| 230 * this method will complete with the same error. | 232 /// call, this method will complete with the same error. |
| 231 */ | 233 async.Future<Policy> setIamPolicy( |
| 232 async.Future<Policy> setIamPolicy(SetIamPolicyRequest request, core.String res
ource) { | 234 SetIamPolicyRequest request, core.String resource) { |
| 233 var _url = null; | 235 var _url = null; |
| 234 var _queryParams = new core.Map(); | 236 var _queryParams = new core.Map(); |
| 235 var _uploadMedia = null; | 237 var _uploadMedia = null; |
| 236 var _uploadOptions = null; | 238 var _uploadOptions = null; |
| 237 var _downloadOptions = commons.DownloadOptions.Metadata; | 239 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 238 var _body = null; | 240 var _body = null; |
| 239 | 241 |
| 240 if (request != null) { | 242 if (request != null) { |
| 241 _body = convert.JSON.encode((request).toJson()); | 243 _body = convert.JSON.encode((request).toJson()); |
| 242 } | 244 } |
| 243 if (resource == null) { | 245 if (resource == null) { |
| 244 throw new core.ArgumentError("Parameter resource is required."); | 246 throw new core.ArgumentError("Parameter resource is required."); |
| 245 } | 247 } |
| 246 | 248 |
| 247 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':s
etIamPolicy'; | 249 _url = 'v1beta1/' + |
| 250 commons.Escaper.ecapeVariableReserved('$resource') + |
| 251 ':setIamPolicy'; |
| 248 | 252 |
| 249 var _response = _requester.request(_url, | 253 var _response = _requester.request(_url, "POST", |
| 250 "POST", | 254 body: _body, |
| 251 body: _body, | 255 queryParams: _queryParams, |
| 252 queryParams: _queryParams, | 256 uploadOptions: _uploadOptions, |
| 253 uploadOptions: _uploadOptions, | 257 uploadMedia: _uploadMedia, |
| 254 uploadMedia: _uploadMedia, | 258 downloadOptions: _downloadOptions); |
| 255 downloadOptions: _downloadOptions); | |
| 256 return _response.then((data) => new Policy.fromJson(data)); | 259 return _response.then((data) => new Policy.fromJson(data)); |
| 257 } | 260 } |
| 258 | 261 |
| 259 /** | 262 /// Returns permissions that a caller has on the specified Organization. |
| 260 * Returns permissions that a caller has on the specified Organization. | 263 /// The `resource` field should be the organization's resource name, |
| 261 * The `resource` field should be the organization's resource name, | 264 /// e.g. "organizations/123". |
| 262 * e.g. "organizations/123". | 265 /// |
| 263 * | 266 /// [request] - The metadata request object. |
| 264 * [request] - The metadata request object. | 267 /// |
| 265 * | 268 /// Request parameters: |
| 266 * Request parameters: | 269 /// |
| 267 * | 270 /// [resource] - REQUIRED: The resource for which the policy detail is being |
| 268 * [resource] - REQUIRED: The resource for which the policy detail is being | 271 /// requested. |
| 269 * requested. | 272 /// See the operation documentation for the appropriate value for this field. |
| 270 * See the operation documentation for the appropriate value for this field. | 273 /// Value must have pattern "^organizations/[^/]+$". |
| 271 * Value must have pattern "^organizations/[^/]+$". | 274 /// |
| 272 * | 275 /// Completes with a [TestIamPermissionsResponse]. |
| 273 * Completes with a [TestIamPermissionsResponse]. | 276 /// |
| 274 * | 277 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 275 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 278 /// an error. |
| 276 * error. | 279 /// |
| 277 * | 280 /// If the used [http.Client] completes with an error when making a REST |
| 278 * If the used [http.Client] completes with an error when making a REST call, | 281 /// call, this method will complete with the same error. |
| 279 * this method will complete with the same error. | 282 async.Future<TestIamPermissionsResponse> testIamPermissions( |
| 280 */ | 283 TestIamPermissionsRequest request, core.String resource) { |
| 281 async.Future<TestIamPermissionsResponse> testIamPermissions(TestIamPermissions
Request request, core.String resource) { | |
| 282 var _url = null; | 284 var _url = null; |
| 283 var _queryParams = new core.Map(); | 285 var _queryParams = new core.Map(); |
| 284 var _uploadMedia = null; | 286 var _uploadMedia = null; |
| 285 var _uploadOptions = null; | 287 var _uploadOptions = null; |
| 286 var _downloadOptions = commons.DownloadOptions.Metadata; | 288 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 287 var _body = null; | 289 var _body = null; |
| 288 | 290 |
| 289 if (request != null) { | 291 if (request != null) { |
| 290 _body = convert.JSON.encode((request).toJson()); | 292 _body = convert.JSON.encode((request).toJson()); |
| 291 } | 293 } |
| 292 if (resource == null) { | 294 if (resource == null) { |
| 293 throw new core.ArgumentError("Parameter resource is required."); | 295 throw new core.ArgumentError("Parameter resource is required."); |
| 294 } | 296 } |
| 295 | 297 |
| 296 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':t
estIamPermissions'; | 298 _url = 'v1beta1/' + |
| 299 commons.Escaper.ecapeVariableReserved('$resource') + |
| 300 ':testIamPermissions'; |
| 297 | 301 |
| 298 var _response = _requester.request(_url, | 302 var _response = _requester.request(_url, "POST", |
| 299 "POST", | 303 body: _body, |
| 300 body: _body, | 304 queryParams: _queryParams, |
| 301 queryParams: _queryParams, | 305 uploadOptions: _uploadOptions, |
| 302 uploadOptions: _uploadOptions, | 306 uploadMedia: _uploadMedia, |
| 303 uploadMedia: _uploadMedia, | 307 downloadOptions: _downloadOptions); |
| 304 downloadOptions: _downloadOptions); | 308 return _response |
| 305 return _response.then((data) => new TestIamPermissionsResponse.fromJson(data
)); | 309 .then((data) => new TestIamPermissionsResponse.fromJson(data)); |
| 306 } | 310 } |
| 307 | 311 |
| 308 /** | 312 /// Updates an Organization resource identified by the specified resource |
| 309 * Updates an Organization resource identified by the specified resource name. | 313 /// name. |
| 310 * | 314 /// |
| 311 * [request] - The metadata request object. | 315 /// [request] - The metadata request object. |
| 312 * | 316 /// |
| 313 * Request parameters: | 317 /// Request parameters: |
| 314 * | 318 /// |
| 315 * [name] - Output Only. The resource name of the organization. This is the | 319 /// [name] - Output Only. The resource name of the organization. This is the |
| 316 * organization's relative path in the API. Its format is | 320 /// organization's relative path in the API. Its format is |
| 317 * "organizations/[organization_id]". For example, "organizations/1234". | 321 /// "organizations/[organization_id]". For example, "organizations/1234". |
| 318 * Value must have pattern "^organizations/[^/]+$". | 322 /// Value must have pattern "^organizations/[^/]+$". |
| 319 * | 323 /// |
| 320 * Completes with a [Organization]. | 324 /// Completes with a [Organization]. |
| 321 * | 325 /// |
| 322 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 326 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 323 * error. | 327 /// an error. |
| 324 * | 328 /// |
| 325 * If the used [http.Client] completes with an error when making a REST call, | 329 /// If the used [http.Client] completes with an error when making a REST |
| 326 * this method will complete with the same error. | 330 /// call, this method will complete with the same error. |
| 327 */ | |
| 328 async.Future<Organization> update(Organization request, core.String name) { | 331 async.Future<Organization> update(Organization request, core.String name) { |
| 329 var _url = null; | 332 var _url = null; |
| 330 var _queryParams = new core.Map(); | 333 var _queryParams = new core.Map(); |
| 331 var _uploadMedia = null; | 334 var _uploadMedia = null; |
| 332 var _uploadOptions = null; | 335 var _uploadOptions = null; |
| 333 var _downloadOptions = commons.DownloadOptions.Metadata; | 336 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 334 var _body = null; | 337 var _body = null; |
| 335 | 338 |
| 336 if (request != null) { | 339 if (request != null) { |
| 337 _body = convert.JSON.encode((request).toJson()); | 340 _body = convert.JSON.encode((request).toJson()); |
| 338 } | 341 } |
| 339 if (name == null) { | 342 if (name == null) { |
| 340 throw new core.ArgumentError("Parameter name is required."); | 343 throw new core.ArgumentError("Parameter name is required."); |
| 341 } | 344 } |
| 342 | 345 |
| 343 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$name'); | 346 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 344 | 347 |
| 345 var _response = _requester.request(_url, | 348 var _response = _requester.request(_url, "PUT", |
| 346 "PUT", | 349 body: _body, |
| 347 body: _body, | 350 queryParams: _queryParams, |
| 348 queryParams: _queryParams, | 351 uploadOptions: _uploadOptions, |
| 349 uploadOptions: _uploadOptions, | 352 uploadMedia: _uploadMedia, |
| 350 uploadMedia: _uploadMedia, | 353 downloadOptions: _downloadOptions); |
| 351 downloadOptions: _downloadOptions); | |
| 352 return _response.then((data) => new Organization.fromJson(data)); | 354 return _response.then((data) => new Organization.fromJson(data)); |
| 353 } | 355 } |
| 354 | |
| 355 } | 356 } |
| 356 | 357 |
| 357 | |
| 358 class ProjectsResourceApi { | 358 class ProjectsResourceApi { |
| 359 final commons.ApiRequester _requester; | 359 final commons.ApiRequester _requester; |
| 360 | 360 |
| 361 ProjectsResourceApi(commons.ApiRequester client) : | 361 ProjectsResourceApi(commons.ApiRequester client) : _requester = client; |
| 362 _requester = client; | |
| 363 | 362 |
| 364 /** | 363 /// Creates a Project resource. |
| 365 * Creates a Project resource. | 364 /// |
| 366 * | 365 /// Initially, the Project resource is owned by its creator exclusively. |
| 367 * Initially, the Project resource is owned by its creator exclusively. | 366 /// The creator can later grant permission to others to read or update the |
| 368 * The creator can later grant permission to others to read or update the | 367 /// Project. |
| 369 * Project. | 368 /// |
| 370 * | 369 /// Several APIs are activated automatically for the Project, including |
| 371 * Several APIs are activated automatically for the Project, including | 370 /// Google Cloud Storage. |
| 372 * Google Cloud Storage. | 371 /// |
| 373 * | 372 /// [request] - The metadata request object. |
| 374 * [request] - The metadata request object. | 373 /// |
| 375 * | 374 /// Request parameters: |
| 376 * Request parameters: | 375 /// |
| 377 * | 376 /// [useLegacyStack] - A safety hatch to opt out of the new reliable project |
| 378 * [useLegacyStack] - A safety hatch to opt out of the new reliable project | 377 /// creation process. |
| 379 * creation process. | 378 /// |
| 380 * | 379 /// Completes with a [Project]. |
| 381 * Completes with a [Project]. | 380 /// |
| 382 * | 381 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 383 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 382 /// an error. |
| 384 * error. | 383 /// |
| 385 * | 384 /// If the used [http.Client] completes with an error when making a REST |
| 386 * If the used [http.Client] completes with an error when making a REST call, | 385 /// call, this method will complete with the same error. |
| 387 * this method will complete with the same error. | |
| 388 */ | |
| 389 async.Future<Project> create(Project request, {core.bool useLegacyStack}) { | 386 async.Future<Project> create(Project request, {core.bool useLegacyStack}) { |
| 390 var _url = null; | 387 var _url = null; |
| 391 var _queryParams = new core.Map(); | 388 var _queryParams = new core.Map(); |
| 392 var _uploadMedia = null; | 389 var _uploadMedia = null; |
| 393 var _uploadOptions = null; | 390 var _uploadOptions = null; |
| 394 var _downloadOptions = commons.DownloadOptions.Metadata; | 391 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 395 var _body = null; | 392 var _body = null; |
| 396 | 393 |
| 397 if (request != null) { | 394 if (request != null) { |
| 398 _body = convert.JSON.encode((request).toJson()); | 395 _body = convert.JSON.encode((request).toJson()); |
| 399 } | 396 } |
| 400 if (useLegacyStack != null) { | 397 if (useLegacyStack != null) { |
| 401 _queryParams["useLegacyStack"] = ["${useLegacyStack}"]; | 398 _queryParams["useLegacyStack"] = ["${useLegacyStack}"]; |
| 402 } | 399 } |
| 403 | 400 |
| 404 _url = 'v1beta1/projects'; | 401 _url = 'v1beta1/projects'; |
| 405 | 402 |
| 406 var _response = _requester.request(_url, | 403 var _response = _requester.request(_url, "POST", |
| 407 "POST", | 404 body: _body, |
| 408 body: _body, | 405 queryParams: _queryParams, |
| 409 queryParams: _queryParams, | 406 uploadOptions: _uploadOptions, |
| 410 uploadOptions: _uploadOptions, | 407 uploadMedia: _uploadMedia, |
| 411 uploadMedia: _uploadMedia, | 408 downloadOptions: _downloadOptions); |
| 412 downloadOptions: _downloadOptions); | |
| 413 return _response.then((data) => new Project.fromJson(data)); | 409 return _response.then((data) => new Project.fromJson(data)); |
| 414 } | 410 } |
| 415 | 411 |
| 416 /** | 412 /// Marks the Project identified by the specified |
| 417 * Marks the Project identified by the specified | 413 /// `project_id` (for example, `my-project-123`) for deletion. |
| 418 * `project_id` (for example, `my-project-123`) for deletion. | 414 /// This method will only affect the Project if the following criteria are |
| 419 * This method will only affect the Project if the following criteria are met: | 415 /// met: |
| 420 * | 416 /// |
| 421 * + The Project does not have a billing account associated with it. | 417 /// + The Project does not have a billing account associated with it. |
| 422 * + The Project has a lifecycle state of | 418 /// + The Project has a lifecycle state of |
| 423 * ACTIVE. | 419 /// ACTIVE. |
| 424 * | 420 /// |
| 425 * This method changes the Project's lifecycle state from | 421 /// This method changes the Project's lifecycle state from |
| 426 * ACTIVE | 422 /// ACTIVE |
| 427 * to DELETE_REQUESTED. | 423 /// to DELETE_REQUESTED. |
| 428 * The deletion starts at an unspecified time, at which point the project is | 424 /// The deletion starts at an unspecified time, at which point the project is |
| 429 * no longer accessible. | 425 /// no longer accessible. |
| 430 * | 426 /// |
| 431 * Until the deletion completes, you can check the lifecycle state | 427 /// Until the deletion completes, you can check the lifecycle state |
| 432 * checked by retrieving the Project with GetProject, | 428 /// checked by retrieving the Project with GetProject, |
| 433 * and the Project remains visible to ListProjects. | 429 /// and the Project remains visible to ListProjects. |
| 434 * However, you cannot update the project. | 430 /// However, you cannot update the project. |
| 435 * | 431 /// |
| 436 * After the deletion completes, the Project is not retrievable by | 432 /// After the deletion completes, the Project is not retrievable by |
| 437 * the GetProject and | 433 /// the GetProject and |
| 438 * ListProjects methods. | 434 /// ListProjects methods. |
| 439 * | 435 /// |
| 440 * The caller must have modify permissions for this Project. | 436 /// The caller must have modify permissions for this Project. |
| 441 * | 437 /// |
| 442 * Request parameters: | 438 /// Request parameters: |
| 443 * | 439 /// |
| 444 * [projectId] - The Project ID (for example, `foo-bar-123`). | 440 /// [projectId] - The Project ID (for example, `foo-bar-123`). |
| 445 * | 441 /// |
| 446 * Required. | 442 /// Required. |
| 447 * | 443 /// |
| 448 * Completes with a [Empty]. | 444 /// Completes with a [Empty]. |
| 449 * | 445 /// |
| 450 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 446 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 451 * error. | 447 /// an error. |
| 452 * | 448 /// |
| 453 * If the used [http.Client] completes with an error when making a REST call, | 449 /// If the used [http.Client] completes with an error when making a REST |
| 454 * this method will complete with the same error. | 450 /// call, this method will complete with the same error. |
| 455 */ | |
| 456 async.Future<Empty> delete(core.String projectId) { | 451 async.Future<Empty> delete(core.String projectId) { |
| 457 var _url = null; | 452 var _url = null; |
| 458 var _queryParams = new core.Map(); | 453 var _queryParams = new core.Map(); |
| 459 var _uploadMedia = null; | 454 var _uploadMedia = null; |
| 460 var _uploadOptions = null; | 455 var _uploadOptions = null; |
| 461 var _downloadOptions = commons.DownloadOptions.Metadata; | 456 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 462 var _body = null; | 457 var _body = null; |
| 463 | 458 |
| 464 if (projectId == null) { | 459 if (projectId == null) { |
| 465 throw new core.ArgumentError("Parameter projectId is required."); | 460 throw new core.ArgumentError("Parameter projectId is required."); |
| 466 } | 461 } |
| 467 | 462 |
| 468 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId'); | 463 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId'); |
| 469 | 464 |
| 470 var _response = _requester.request(_url, | 465 var _response = _requester.request(_url, "DELETE", |
| 471 "DELETE", | 466 body: _body, |
| 472 body: _body, | 467 queryParams: _queryParams, |
| 473 queryParams: _queryParams, | 468 uploadOptions: _uploadOptions, |
| 474 uploadOptions: _uploadOptions, | 469 uploadMedia: _uploadMedia, |
| 475 uploadMedia: _uploadMedia, | 470 downloadOptions: _downloadOptions); |
| 476 downloadOptions: _downloadOptions); | |
| 477 return _response.then((data) => new Empty.fromJson(data)); | 471 return _response.then((data) => new Empty.fromJson(data)); |
| 478 } | 472 } |
| 479 | 473 |
| 480 /** | 474 /// Retrieves the Project identified by the specified |
| 481 * Retrieves the Project identified by the specified | 475 /// `project_id` (for example, `my-project-123`). |
| 482 * `project_id` (for example, `my-project-123`). | 476 /// |
| 483 * | 477 /// The caller must have read permissions for this Project. |
| 484 * The caller must have read permissions for this Project. | 478 /// |
| 485 * | 479 /// Request parameters: |
| 486 * Request parameters: | 480 /// |
| 487 * | 481 /// [projectId] - The Project ID (for example, `my-project-123`). |
| 488 * [projectId] - The Project ID (for example, `my-project-123`). | 482 /// |
| 489 * | 483 /// Required. |
| 490 * Required. | 484 /// |
| 491 * | 485 /// Completes with a [Project]. |
| 492 * Completes with a [Project]. | 486 /// |
| 493 * | 487 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 494 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 488 /// an error. |
| 495 * error. | 489 /// |
| 496 * | 490 /// If the used [http.Client] completes with an error when making a REST |
| 497 * If the used [http.Client] completes with an error when making a REST call, | 491 /// call, this method will complete with the same error. |
| 498 * this method will complete with the same error. | |
| 499 */ | |
| 500 async.Future<Project> get(core.String projectId) { | 492 async.Future<Project> get(core.String projectId) { |
| 501 var _url = null; | 493 var _url = null; |
| 502 var _queryParams = new core.Map(); | 494 var _queryParams = new core.Map(); |
| 503 var _uploadMedia = null; | 495 var _uploadMedia = null; |
| 504 var _uploadOptions = null; | 496 var _uploadOptions = null; |
| 505 var _downloadOptions = commons.DownloadOptions.Metadata; | 497 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 506 var _body = null; | 498 var _body = null; |
| 507 | 499 |
| 508 if (projectId == null) { | 500 if (projectId == null) { |
| 509 throw new core.ArgumentError("Parameter projectId is required."); | 501 throw new core.ArgumentError("Parameter projectId is required."); |
| 510 } | 502 } |
| 511 | 503 |
| 512 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId'); | 504 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId'); |
| 513 | 505 |
| 514 var _response = _requester.request(_url, | 506 var _response = _requester.request(_url, "GET", |
| 515 "GET", | 507 body: _body, |
| 516 body: _body, | 508 queryParams: _queryParams, |
| 517 queryParams: _queryParams, | 509 uploadOptions: _uploadOptions, |
| 518 uploadOptions: _uploadOptions, | 510 uploadMedia: _uploadMedia, |
| 519 uploadMedia: _uploadMedia, | 511 downloadOptions: _downloadOptions); |
| 520 downloadOptions: _downloadOptions); | |
| 521 return _response.then((data) => new Project.fromJson(data)); | 512 return _response.then((data) => new Project.fromJson(data)); |
| 522 } | 513 } |
| 523 | 514 |
| 524 /** | 515 /// Gets a list of ancestors in the resource hierarchy for the Project |
| 525 * Gets a list of ancestors in the resource hierarchy for the Project | 516 /// identified by the specified `project_id` (for example, `my-project-123`). |
| 526 * identified by the specified `project_id` (for example, `my-project-123`). | 517 /// |
| 527 * | 518 /// The caller must have read permissions for this Project. |
| 528 * The caller must have read permissions for this Project. | 519 /// |
| 529 * | 520 /// [request] - The metadata request object. |
| 530 * [request] - The metadata request object. | 521 /// |
| 531 * | 522 /// Request parameters: |
| 532 * Request parameters: | 523 /// |
| 533 * | 524 /// [projectId] - The Project ID (for example, `my-project-123`). |
| 534 * [projectId] - The Project ID (for example, `my-project-123`). | 525 /// |
| 535 * | 526 /// Required. |
| 536 * Required. | 527 /// |
| 537 * | 528 /// Completes with a [GetAncestryResponse]. |
| 538 * Completes with a [GetAncestryResponse]. | 529 /// |
| 539 * | 530 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 540 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 531 /// an error. |
| 541 * error. | 532 /// |
| 542 * | 533 /// If the used [http.Client] completes with an error when making a REST |
| 543 * If the used [http.Client] completes with an error when making a REST call, | 534 /// call, this method will complete with the same error. |
| 544 * this method will complete with the same error. | 535 async.Future<GetAncestryResponse> getAncestry( |
| 545 */ | 536 GetAncestryRequest request, core.String projectId) { |
| 546 async.Future<GetAncestryResponse> getAncestry(GetAncestryRequest request, core
.String projectId) { | |
| 547 var _url = null; | 537 var _url = null; |
| 548 var _queryParams = new core.Map(); | 538 var _queryParams = new core.Map(); |
| 549 var _uploadMedia = null; | 539 var _uploadMedia = null; |
| 550 var _uploadOptions = null; | 540 var _uploadOptions = null; |
| 551 var _downloadOptions = commons.DownloadOptions.Metadata; | 541 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 552 var _body = null; | 542 var _body = null; |
| 553 | 543 |
| 554 if (request != null) { | 544 if (request != null) { |
| 555 _body = convert.JSON.encode((request).toJson()); | 545 _body = convert.JSON.encode((request).toJson()); |
| 556 } | 546 } |
| 557 if (projectId == null) { | 547 if (projectId == null) { |
| 558 throw new core.ArgumentError("Parameter projectId is required."); | 548 throw new core.ArgumentError("Parameter projectId is required."); |
| 559 } | 549 } |
| 560 | 550 |
| 561 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId') + '
:getAncestry'; | 551 _url = 'v1beta1/projects/' + |
| 552 commons.Escaper.ecapeVariable('$projectId') + |
| 553 ':getAncestry'; |
| 562 | 554 |
| 563 var _response = _requester.request(_url, | 555 var _response = _requester.request(_url, "POST", |
| 564 "POST", | 556 body: _body, |
| 565 body: _body, | 557 queryParams: _queryParams, |
| 566 queryParams: _queryParams, | 558 uploadOptions: _uploadOptions, |
| 567 uploadOptions: _uploadOptions, | 559 uploadMedia: _uploadMedia, |
| 568 uploadMedia: _uploadMedia, | 560 downloadOptions: _downloadOptions); |
| 569 downloadOptions: _downloadOptions); | |
| 570 return _response.then((data) => new GetAncestryResponse.fromJson(data)); | 561 return _response.then((data) => new GetAncestryResponse.fromJson(data)); |
| 571 } | 562 } |
| 572 | 563 |
| 573 /** | 564 /// Returns the IAM access control policy for the specified Project. |
| 574 * Returns the IAM access control policy for the specified Project. | 565 /// Permission is denied if the policy or the resource does not exist. |
| 575 * Permission is denied if the policy or the resource does not exist. | 566 /// |
| 576 * | 567 /// [request] - The metadata request object. |
| 577 * [request] - The metadata request object. | 568 /// |
| 578 * | 569 /// Request parameters: |
| 579 * Request parameters: | 570 /// |
| 580 * | 571 /// [resource] - REQUIRED: The resource for which the policy is being |
| 581 * [resource] - REQUIRED: The resource for which the policy is being | 572 /// requested. |
| 582 * requested. | 573 /// See the operation documentation for the appropriate value for this field. |
| 583 * See the operation documentation for the appropriate value for this field. | 574 /// |
| 584 * | 575 /// Completes with a [Policy]. |
| 585 * Completes with a [Policy]. | 576 /// |
| 586 * | 577 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 587 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 578 /// an error. |
| 588 * error. | 579 /// |
| 589 * | 580 /// If the used [http.Client] completes with an error when making a REST |
| 590 * If the used [http.Client] completes with an error when making a REST call, | 581 /// call, this method will complete with the same error. |
| 591 * this method will complete with the same error. | 582 async.Future<Policy> getIamPolicy( |
| 592 */ | 583 GetIamPolicyRequest request, core.String resource) { |
| 593 async.Future<Policy> getIamPolicy(GetIamPolicyRequest request, core.String res
ource) { | |
| 594 var _url = null; | 584 var _url = null; |
| 595 var _queryParams = new core.Map(); | 585 var _queryParams = new core.Map(); |
| 596 var _uploadMedia = null; | 586 var _uploadMedia = null; |
| 597 var _uploadOptions = null; | 587 var _uploadOptions = null; |
| 598 var _downloadOptions = commons.DownloadOptions.Metadata; | 588 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 599 var _body = null; | 589 var _body = null; |
| 600 | 590 |
| 601 if (request != null) { | 591 if (request != null) { |
| 602 _body = convert.JSON.encode((request).toJson()); | 592 _body = convert.JSON.encode((request).toJson()); |
| 603 } | 593 } |
| 604 if (resource == null) { | 594 if (resource == null) { |
| 605 throw new core.ArgumentError("Parameter resource is required."); | 595 throw new core.ArgumentError("Parameter resource is required."); |
| 606 } | 596 } |
| 607 | 597 |
| 608 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$resource') + ':
getIamPolicy'; | 598 _url = 'v1beta1/projects/' + |
| 599 commons.Escaper.ecapeVariable('$resource') + |
| 600 ':getIamPolicy'; |
| 609 | 601 |
| 610 var _response = _requester.request(_url, | 602 var _response = _requester.request(_url, "POST", |
| 611 "POST", | 603 body: _body, |
| 612 body: _body, | 604 queryParams: _queryParams, |
| 613 queryParams: _queryParams, | 605 uploadOptions: _uploadOptions, |
| 614 uploadOptions: _uploadOptions, | 606 uploadMedia: _uploadMedia, |
| 615 uploadMedia: _uploadMedia, | 607 downloadOptions: _downloadOptions); |
| 616 downloadOptions: _downloadOptions); | |
| 617 return _response.then((data) => new Policy.fromJson(data)); | 608 return _response.then((data) => new Policy.fromJson(data)); |
| 618 } | 609 } |
| 619 | 610 |
| 620 /** | 611 /// Lists Projects that are visible to the user and satisfy the |
| 621 * Lists Projects that are visible to the user and satisfy the | 612 /// specified filter. This method returns Projects in an unspecified order. |
| 622 * specified filter. This method returns Projects in an unspecified order. | 613 /// New Projects do not necessarily appear at the end of the list. |
| 623 * New Projects do not necessarily appear at the end of the list. | 614 /// |
| 624 * | 615 /// Request parameters: |
| 625 * Request parameters: | 616 /// |
| 626 * | 617 /// [filter] - An expression for filtering the results of the request. |
| 627 * [pageToken] - A pagination token returned from a previous call to | 618 /// Filter rules are |
| 628 * ListProjects | 619 /// case insensitive. The fields eligible for filtering are: |
| 629 * that indicates from where listing should continue. | 620 /// |
| 630 * | 621 /// + `name` |
| 631 * Optional. | 622 /// + `id` |
| 632 * | 623 /// + <code>labels.<em>key</em></code> where *key* is the name of a label |
| 633 * [pageSize] - The maximum number of Projects to return in the response. | 624 /// |
| 634 * The server can return fewer Projects than requested. | 625 /// Some examples of using labels as filters: |
| 635 * If unspecified, server picks an appropriate default. | 626 /// |
| 636 * | 627 /// |Filter|Description| |
| 637 * Optional. | 628 /// |------|-----------| |
| 638 * | 629 /// |name:how*|The project's name starts with "how".| |
| 639 * [filter] - An expression for filtering the results of the request. Filter | 630 /// |name:Howl|The project's name is `Howl` or `howl`.| |
| 640 * rules are | 631 /// |name:HOWL|Equivalent to above.| |
| 641 * case insensitive. The fields eligible for filtering are: | 632 /// |NAME:howl|Equivalent to above.| |
| 642 * | 633 /// |labels.color:*|The project has the label `color`.| |
| 643 * + `name` | 634 /// |labels.color:red|The project's label `color` has the value `red`.| |
| 644 * + `id` | 635 /// |labels.color:red labels.size:big|The project's label `color` has |
| 645 * + <code>labels.<em>key</em></code> where *key* is the name of a label | 636 /// the value `red` and its label `size` has the value `big`. |
| 646 * | 637 /// |
| 647 * Some examples of using labels as filters: | 638 /// If you specify a filter that has both `parent.type` and `parent.id`, then |
| 648 * | 639 /// the `resourcemanager.projects.list` permission is checked on the parent. |
| 649 * |Filter|Description| | 640 /// If the user has this permission, all projects under the parent will be |
| 650 * |------|-----------| | 641 /// returned after remaining filters have been applied. If the user lacks |
| 651 * |name:how*|The project's name starts with "how".| | 642 /// this |
| 652 * |name:Howl|The project's name is `Howl` or `howl`.| | 643 /// permission, then all projects for which the user has the |
| 653 * |name:HOWL|Equivalent to above.| | 644 /// `resourcemanager.projects.get` permission will be returned after |
| 654 * |NAME:howl|Equivalent to above.| | 645 /// remaining |
| 655 * |labels.color:*|The project has the label `color`.| | 646 /// filters have been applied. If no filter is specified, the call will |
| 656 * |labels.color:red|The project's label `color` has the value `red`.| | 647 /// return |
| 657 * |labels.color:red labels.size:big|The project's label `color` has the | 648 /// projects for which the user has `resourcemanager.projects.get` |
| 658 * value `red` and its label `size` has the value `big`. | 649 /// permissions. |
| 659 * | 650 /// |
| 660 * If you specify a filter that has both `parent.type` and `parent.id`, then | 651 /// Optional. |
| 661 * the `resourcemanager.projects.list` permission is checked on the parent. | 652 /// |
| 662 * If the user has this permission, all projects under the parent will be | 653 /// [pageToken] - A pagination token returned from a previous call to |
| 663 * returned after remaining filters have been applied. If the user lacks this | 654 /// ListProjects |
| 664 * permission, then all projects for which the user has the | 655 /// that indicates from where listing should continue. |
| 665 * `resourcemanager.projects.get` permission will be returned after remaining | 656 /// |
| 666 * filters have been applied. If no filter is specified, the call will return | 657 /// Optional. |
| 667 * projects for which the user has `resourcemanager.projects.get` permissions. | 658 /// |
| 668 * | 659 /// [pageSize] - The maximum number of Projects to return in the response. |
| 669 * Optional. | 660 /// The server can return fewer Projects than requested. |
| 670 * | 661 /// If unspecified, server picks an appropriate default. |
| 671 * Completes with a [ListProjectsResponse]. | 662 /// |
| 672 * | 663 /// Optional. |
| 673 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 664 /// |
| 674 * error. | 665 /// Completes with a [ListProjectsResponse]. |
| 675 * | 666 /// |
| 676 * If the used [http.Client] completes with an error when making a REST call, | 667 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 677 * this method will complete with the same error. | 668 /// an error. |
| 678 */ | 669 /// |
| 679 async.Future<ListProjectsResponse> list({core.String pageToken, core.int pageS
ize, core.String filter}) { | 670 /// If the used [http.Client] completes with an error when making a REST |
| 671 /// call, this method will complete with the same error. |
| 672 async.Future<ListProjectsResponse> list( |
| 673 {core.String filter, core.String pageToken, core.int pageSize}) { |
| 680 var _url = null; | 674 var _url = null; |
| 681 var _queryParams = new core.Map(); | 675 var _queryParams = new core.Map(); |
| 682 var _uploadMedia = null; | 676 var _uploadMedia = null; |
| 683 var _uploadOptions = null; | 677 var _uploadOptions = null; |
| 684 var _downloadOptions = commons.DownloadOptions.Metadata; | 678 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 685 var _body = null; | 679 var _body = null; |
| 686 | 680 |
| 681 if (filter != null) { |
| 682 _queryParams["filter"] = [filter]; |
| 683 } |
| 687 if (pageToken != null) { | 684 if (pageToken != null) { |
| 688 _queryParams["pageToken"] = [pageToken]; | 685 _queryParams["pageToken"] = [pageToken]; |
| 689 } | 686 } |
| 690 if (pageSize != null) { | 687 if (pageSize != null) { |
| 691 _queryParams["pageSize"] = ["${pageSize}"]; | 688 _queryParams["pageSize"] = ["${pageSize}"]; |
| 692 } | 689 } |
| 693 if (filter != null) { | |
| 694 _queryParams["filter"] = [filter]; | |
| 695 } | |
| 696 | 690 |
| 697 _url = 'v1beta1/projects'; | 691 _url = 'v1beta1/projects'; |
| 698 | 692 |
| 699 var _response = _requester.request(_url, | 693 var _response = _requester.request(_url, "GET", |
| 700 "GET", | 694 body: _body, |
| 701 body: _body, | 695 queryParams: _queryParams, |
| 702 queryParams: _queryParams, | 696 uploadOptions: _uploadOptions, |
| 703 uploadOptions: _uploadOptions, | 697 uploadMedia: _uploadMedia, |
| 704 uploadMedia: _uploadMedia, | 698 downloadOptions: _downloadOptions); |
| 705 downloadOptions: _downloadOptions); | |
| 706 return _response.then((data) => new ListProjectsResponse.fromJson(data)); | 699 return _response.then((data) => new ListProjectsResponse.fromJson(data)); |
| 707 } | 700 } |
| 708 | 701 |
| 709 /** | 702 /// Sets the IAM access control policy for the specified Project. Replaces |
| 710 * Sets the IAM access control policy for the specified Project. Replaces | 703 /// any existing policy. |
| 711 * any existing policy. | 704 /// |
| 712 * | 705 /// The following constraints apply when using `setIamPolicy()`: |
| 713 * The following constraints apply when using `setIamPolicy()`: | 706 /// |
| 714 * | 707 /// + Project does not support `allUsers` and `allAuthenticatedUsers` as |
| 715 * + Project does not support `allUsers` and `allAuthenticatedUsers` as | 708 /// `members` in a `Binding` of a `Policy`. |
| 716 * `members` in a `Binding` of a `Policy`. | 709 /// |
| 717 * | 710 /// + The owner role can be granted only to `user` and `serviceAccount`. |
| 718 * + The owner role can be granted only to `user` and `serviceAccount`. | 711 /// |
| 719 * | 712 /// + Service accounts can be made owners of a project directly |
| 720 * + Service accounts can be made owners of a project directly | 713 /// without any restrictions. However, to be added as an owner, a user must |
| 721 * without any restrictions. However, to be added as an owner, a user must be | 714 /// be |
| 722 * invited via Cloud Platform console and must accept the invitation. | 715 /// invited via Cloud Platform console and must accept the invitation. |
| 723 * | 716 /// |
| 724 * + A user cannot be granted the owner role using `setIamPolicy()`. The user | 717 /// + A user cannot be granted the owner role using `setIamPolicy()`. The |
| 725 * must be granted the owner role using the Cloud Platform Console and must | 718 /// user |
| 726 * explicitly accept the invitation. | 719 /// must be granted the owner role using the Cloud Platform Console and must |
| 727 * | 720 /// explicitly accept the invitation. |
| 728 * + Invitations to grant the owner role cannot be sent using | 721 /// |
| 729 * `setIamPolicy()`; they must be sent only using the Cloud Platform Console. | 722 /// + Invitations to grant the owner role cannot be sent using |
| 730 * | 723 /// `setIamPolicy()`; they must be sent only using the Cloud Platform |
| 731 * + Membership changes that leave the project without any owners that have | 724 /// Console. |
| 732 * accepted the Terms of Service (ToS) will be rejected. | 725 /// |
| 733 * | 726 /// + Membership changes that leave the project without any owners that have |
| 734 * + If the project is not part of an organization, there must be at least | 727 /// accepted the Terms of Service (ToS) will be rejected. |
| 735 * one owner who has accepted the Terms of Service (ToS) agreement in the | 728 /// |
| 736 * policy. Calling `setIamPolicy()` to remove the last ToS-accepted owner | 729 /// + If the project is not part of an organization, there must be at least |
| 737 * from the policy will fail. This restriction also applies to legacy | 730 /// one owner who has accepted the Terms of Service (ToS) agreement in the |
| 738 * projects that no longer have owners who have accepted the ToS. Edits to | 731 /// policy. Calling `setIamPolicy()` to remove the last ToS-accepted owner |
| 739 * IAM policies will be rejected until the lack of a ToS-accepting owner is | 732 /// from the policy will fail. This restriction also applies to legacy |
| 740 * rectified. | 733 /// projects that no longer have owners who have accepted the ToS. Edits to |
| 741 * | 734 /// IAM policies will be rejected until the lack of a ToS-accepting owner is |
| 742 * + Calling this method requires enabling the App Engine Admin API. | 735 /// rectified. |
| 743 * | 736 /// |
| 744 * Note: Removing service accounts from policies or changing their roles | 737 /// + Calling this method requires enabling the App Engine Admin API. |
| 745 * can render services completely inoperable. It is important to understand | 738 /// |
| 746 * how the service account is being used before removing or updating its | 739 /// Note: Removing service accounts from policies or changing their roles |
| 747 * roles. | 740 /// can render services completely inoperable. It is important to understand |
| 748 * | 741 /// how the service account is being used before removing or updating its |
| 749 * [request] - The metadata request object. | 742 /// roles. |
| 750 * | 743 /// |
| 751 * Request parameters: | 744 /// [request] - The metadata request object. |
| 752 * | 745 /// |
| 753 * [resource] - REQUIRED: The resource for which the policy is being | 746 /// Request parameters: |
| 754 * specified. | 747 /// |
| 755 * See the operation documentation for the appropriate value for this field. | 748 /// [resource] - REQUIRED: The resource for which the policy is being |
| 756 * | 749 /// specified. |
| 757 * Completes with a [Policy]. | 750 /// See the operation documentation for the appropriate value for this field. |
| 758 * | 751 /// |
| 759 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 752 /// Completes with a [Policy]. |
| 760 * error. | 753 /// |
| 761 * | 754 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 762 * If the used [http.Client] completes with an error when making a REST call, | 755 /// an error. |
| 763 * this method will complete with the same error. | 756 /// |
| 764 */ | 757 /// If the used [http.Client] completes with an error when making a REST |
| 765 async.Future<Policy> setIamPolicy(SetIamPolicyRequest request, core.String res
ource) { | 758 /// call, this method will complete with the same error. |
| 759 async.Future<Policy> setIamPolicy( |
| 760 SetIamPolicyRequest request, core.String resource) { |
| 766 var _url = null; | 761 var _url = null; |
| 767 var _queryParams = new core.Map(); | 762 var _queryParams = new core.Map(); |
| 768 var _uploadMedia = null; | 763 var _uploadMedia = null; |
| 769 var _uploadOptions = null; | 764 var _uploadOptions = null; |
| 770 var _downloadOptions = commons.DownloadOptions.Metadata; | 765 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 771 var _body = null; | 766 var _body = null; |
| 772 | 767 |
| 773 if (request != null) { | 768 if (request != null) { |
| 774 _body = convert.JSON.encode((request).toJson()); | 769 _body = convert.JSON.encode((request).toJson()); |
| 775 } | 770 } |
| 776 if (resource == null) { | 771 if (resource == null) { |
| 777 throw new core.ArgumentError("Parameter resource is required."); | 772 throw new core.ArgumentError("Parameter resource is required."); |
| 778 } | 773 } |
| 779 | 774 |
| 780 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$resource') + ':
setIamPolicy'; | 775 _url = 'v1beta1/projects/' + |
| 776 commons.Escaper.ecapeVariable('$resource') + |
| 777 ':setIamPolicy'; |
| 781 | 778 |
| 782 var _response = _requester.request(_url, | 779 var _response = _requester.request(_url, "POST", |
| 783 "POST", | 780 body: _body, |
| 784 body: _body, | 781 queryParams: _queryParams, |
| 785 queryParams: _queryParams, | 782 uploadOptions: _uploadOptions, |
| 786 uploadOptions: _uploadOptions, | 783 uploadMedia: _uploadMedia, |
| 787 uploadMedia: _uploadMedia, | 784 downloadOptions: _downloadOptions); |
| 788 downloadOptions: _downloadOptions); | |
| 789 return _response.then((data) => new Policy.fromJson(data)); | 785 return _response.then((data) => new Policy.fromJson(data)); |
| 790 } | 786 } |
| 791 | 787 |
| 792 /** | 788 /// Returns permissions that a caller has on the specified Project. |
| 793 * Returns permissions that a caller has on the specified Project. | 789 /// |
| 794 * | 790 /// [request] - The metadata request object. |
| 795 * [request] - The metadata request object. | 791 /// |
| 796 * | 792 /// Request parameters: |
| 797 * Request parameters: | 793 /// |
| 798 * | 794 /// [resource] - REQUIRED: The resource for which the policy detail is being |
| 799 * [resource] - REQUIRED: The resource for which the policy detail is being | 795 /// requested. |
| 800 * requested. | 796 /// See the operation documentation for the appropriate value for this field. |
| 801 * See the operation documentation for the appropriate value for this field. | 797 /// |
| 802 * | 798 /// Completes with a [TestIamPermissionsResponse]. |
| 803 * Completes with a [TestIamPermissionsResponse]. | 799 /// |
| 804 * | 800 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 805 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 801 /// an error. |
| 806 * error. | 802 /// |
| 807 * | 803 /// If the used [http.Client] completes with an error when making a REST |
| 808 * If the used [http.Client] completes with an error when making a REST call, | 804 /// call, this method will complete with the same error. |
| 809 * this method will complete with the same error. | 805 async.Future<TestIamPermissionsResponse> testIamPermissions( |
| 810 */ | 806 TestIamPermissionsRequest request, core.String resource) { |
| 811 async.Future<TestIamPermissionsResponse> testIamPermissions(TestIamPermissions
Request request, core.String resource) { | |
| 812 var _url = null; | 807 var _url = null; |
| 813 var _queryParams = new core.Map(); | 808 var _queryParams = new core.Map(); |
| 814 var _uploadMedia = null; | 809 var _uploadMedia = null; |
| 815 var _uploadOptions = null; | 810 var _uploadOptions = null; |
| 816 var _downloadOptions = commons.DownloadOptions.Metadata; | 811 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 817 var _body = null; | 812 var _body = null; |
| 818 | 813 |
| 819 if (request != null) { | 814 if (request != null) { |
| 820 _body = convert.JSON.encode((request).toJson()); | 815 _body = convert.JSON.encode((request).toJson()); |
| 821 } | 816 } |
| 822 if (resource == null) { | 817 if (resource == null) { |
| 823 throw new core.ArgumentError("Parameter resource is required."); | 818 throw new core.ArgumentError("Parameter resource is required."); |
| 824 } | 819 } |
| 825 | 820 |
| 826 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$resource') + ':
testIamPermissions'; | 821 _url = 'v1beta1/projects/' + |
| 822 commons.Escaper.ecapeVariable('$resource') + |
| 823 ':testIamPermissions'; |
| 827 | 824 |
| 828 var _response = _requester.request(_url, | 825 var _response = _requester.request(_url, "POST", |
| 829 "POST", | 826 body: _body, |
| 830 body: _body, | 827 queryParams: _queryParams, |
| 831 queryParams: _queryParams, | 828 uploadOptions: _uploadOptions, |
| 832 uploadOptions: _uploadOptions, | 829 uploadMedia: _uploadMedia, |
| 833 uploadMedia: _uploadMedia, | 830 downloadOptions: _downloadOptions); |
| 834 downloadOptions: _downloadOptions); | 831 return _response |
| 835 return _response.then((data) => new TestIamPermissionsResponse.fromJson(data
)); | 832 .then((data) => new TestIamPermissionsResponse.fromJson(data)); |
| 836 } | 833 } |
| 837 | 834 |
| 838 /** | 835 /// Restores the Project identified by the specified |
| 839 * Restores the Project identified by the specified | 836 /// `project_id` (for example, `my-project-123`). |
| 840 * `project_id` (for example, `my-project-123`). | 837 /// You can only use this method for a Project that has a lifecycle state of |
| 841 * You can only use this method for a Project that has a lifecycle state of | 838 /// DELETE_REQUESTED. |
| 842 * DELETE_REQUESTED. | 839 /// After deletion starts, the Project cannot be restored. |
| 843 * After deletion starts, the Project cannot be restored. | 840 /// |
| 844 * | 841 /// The caller must have modify permissions for this Project. |
| 845 * The caller must have modify permissions for this Project. | 842 /// |
| 846 * | 843 /// [request] - The metadata request object. |
| 847 * [request] - The metadata request object. | 844 /// |
| 848 * | 845 /// Request parameters: |
| 849 * Request parameters: | 846 /// |
| 850 * | 847 /// [projectId] - The project ID (for example, `foo-bar-123`). |
| 851 * [projectId] - The project ID (for example, `foo-bar-123`). | 848 /// |
| 852 * | 849 /// Required. |
| 853 * Required. | 850 /// |
| 854 * | 851 /// Completes with a [Empty]. |
| 855 * Completes with a [Empty]. | 852 /// |
| 856 * | 853 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 857 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 854 /// an error. |
| 858 * error. | 855 /// |
| 859 * | 856 /// If the used [http.Client] completes with an error when making a REST |
| 860 * If the used [http.Client] completes with an error when making a REST call, | 857 /// call, this method will complete with the same error. |
| 861 * this method will complete with the same error. | 858 async.Future<Empty> undelete( |
| 862 */ | 859 UndeleteProjectRequest request, core.String projectId) { |
| 863 async.Future<Empty> undelete(UndeleteProjectRequest request, core.String proje
ctId) { | |
| 864 var _url = null; | 860 var _url = null; |
| 865 var _queryParams = new core.Map(); | 861 var _queryParams = new core.Map(); |
| 866 var _uploadMedia = null; | 862 var _uploadMedia = null; |
| 867 var _uploadOptions = null; | 863 var _uploadOptions = null; |
| 868 var _downloadOptions = commons.DownloadOptions.Metadata; | 864 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 869 var _body = null; | 865 var _body = null; |
| 870 | 866 |
| 871 if (request != null) { | 867 if (request != null) { |
| 872 _body = convert.JSON.encode((request).toJson()); | 868 _body = convert.JSON.encode((request).toJson()); |
| 873 } | 869 } |
| 874 if (projectId == null) { | 870 if (projectId == null) { |
| 875 throw new core.ArgumentError("Parameter projectId is required."); | 871 throw new core.ArgumentError("Parameter projectId is required."); |
| 876 } | 872 } |
| 877 | 873 |
| 878 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId') + '
:undelete'; | 874 _url = 'v1beta1/projects/' + |
| 875 commons.Escaper.ecapeVariable('$projectId') + |
| 876 ':undelete'; |
| 879 | 877 |
| 880 var _response = _requester.request(_url, | 878 var _response = _requester.request(_url, "POST", |
| 881 "POST", | 879 body: _body, |
| 882 body: _body, | 880 queryParams: _queryParams, |
| 883 queryParams: _queryParams, | 881 uploadOptions: _uploadOptions, |
| 884 uploadOptions: _uploadOptions, | 882 uploadMedia: _uploadMedia, |
| 885 uploadMedia: _uploadMedia, | 883 downloadOptions: _downloadOptions); |
| 886 downloadOptions: _downloadOptions); | |
| 887 return _response.then((data) => new Empty.fromJson(data)); | 884 return _response.then((data) => new Empty.fromJson(data)); |
| 888 } | 885 } |
| 889 | 886 |
| 890 /** | 887 /// Updates the attributes of the Project identified by the specified |
| 891 * Updates the attributes of the Project identified by the specified | 888 /// `project_id` (for example, `my-project-123`). |
| 892 * `project_id` (for example, `my-project-123`). | 889 /// |
| 893 * | 890 /// The caller must have modify permissions for this Project. |
| 894 * The caller must have modify permissions for this Project. | 891 /// |
| 895 * | 892 /// [request] - The metadata request object. |
| 896 * [request] - The metadata request object. | 893 /// |
| 897 * | 894 /// Request parameters: |
| 898 * Request parameters: | 895 /// |
| 899 * | 896 /// [projectId] - The project ID (for example, `my-project-123`). |
| 900 * [projectId] - The project ID (for example, `my-project-123`). | 897 /// |
| 901 * | 898 /// Required. |
| 902 * Required. | 899 /// |
| 903 * | 900 /// Completes with a [Project]. |
| 904 * Completes with a [Project]. | 901 /// |
| 905 * | 902 /// Completes with a [commons.ApiRequestError] if the API endpoint returned |
| 906 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 903 /// an error. |
| 907 * error. | 904 /// |
| 908 * | 905 /// If the used [http.Client] completes with an error when making a REST |
| 909 * If the used [http.Client] completes with an error when making a REST call, | 906 /// call, this method will complete with the same error. |
| 910 * this method will complete with the same error. | |
| 911 */ | |
| 912 async.Future<Project> update(Project request, core.String projectId) { | 907 async.Future<Project> update(Project request, core.String projectId) { |
| 913 var _url = null; | 908 var _url = null; |
| 914 var _queryParams = new core.Map(); | 909 var _queryParams = new core.Map(); |
| 915 var _uploadMedia = null; | 910 var _uploadMedia = null; |
| 916 var _uploadOptions = null; | 911 var _uploadOptions = null; |
| 917 var _downloadOptions = commons.DownloadOptions.Metadata; | 912 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 918 var _body = null; | 913 var _body = null; |
| 919 | 914 |
| 920 if (request != null) { | 915 if (request != null) { |
| 921 _body = convert.JSON.encode((request).toJson()); | 916 _body = convert.JSON.encode((request).toJson()); |
| 922 } | 917 } |
| 923 if (projectId == null) { | 918 if (projectId == null) { |
| 924 throw new core.ArgumentError("Parameter projectId is required."); | 919 throw new core.ArgumentError("Parameter projectId is required."); |
| 925 } | 920 } |
| 926 | 921 |
| 927 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId'); | 922 _url = 'v1beta1/projects/' + commons.Escaper.ecapeVariable('$projectId'); |
| 928 | 923 |
| 929 var _response = _requester.request(_url, | 924 var _response = _requester.request(_url, "PUT", |
| 930 "PUT", | 925 body: _body, |
| 931 body: _body, | 926 queryParams: _queryParams, |
| 932 queryParams: _queryParams, | 927 uploadOptions: _uploadOptions, |
| 933 uploadOptions: _uploadOptions, | 928 uploadMedia: _uploadMedia, |
| 934 uploadMedia: _uploadMedia, | 929 downloadOptions: _downloadOptions); |
| 935 downloadOptions: _downloadOptions); | |
| 936 return _response.then((data) => new Project.fromJson(data)); | 930 return _response.then((data) => new Project.fromJson(data)); |
| 937 } | 931 } |
| 938 | |
| 939 } | 932 } |
| 940 | 933 |
| 941 | 934 /// Identifying information for a single ancestor of a project. |
| 942 | |
| 943 /** Identifying information for a single ancestor of a project. */ | |
| 944 class Ancestor { | 935 class Ancestor { |
| 945 /** Resource id of the ancestor. */ | 936 /// Resource id of the ancestor. |
| 946 ResourceId resourceId; | 937 ResourceId resourceId; |
| 947 | 938 |
| 948 Ancestor(); | 939 Ancestor(); |
| 949 | 940 |
| 950 Ancestor.fromJson(core.Map _json) { | 941 Ancestor.fromJson(core.Map _json) { |
| 951 if (_json.containsKey("resourceId")) { | 942 if (_json.containsKey("resourceId")) { |
| 952 resourceId = new ResourceId.fromJson(_json["resourceId"]); | 943 resourceId = new ResourceId.fromJson(_json["resourceId"]); |
| 953 } | 944 } |
| 954 } | 945 } |
| 955 | 946 |
| 956 core.Map<core.String, core.Object> toJson() { | 947 core.Map<core.String, core.Object> toJson() { |
| 957 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 948 final core.Map<core.String, core.Object> _json = |
| 949 new core.Map<core.String, core.Object>(); |
| 958 if (resourceId != null) { | 950 if (resourceId != null) { |
| 959 _json["resourceId"] = (resourceId).toJson(); | 951 _json["resourceId"] = (resourceId).toJson(); |
| 960 } | 952 } |
| 961 return _json; | 953 return _json; |
| 962 } | 954 } |
| 963 } | 955 } |
| 964 | 956 |
| 965 /** | 957 /// Specifies the audit configuration for a service. |
| 966 * Specifies the audit configuration for a service. | 958 /// The configuration determines which permission types are logged, and what |
| 967 * The configuration determines which permission types are logged, and what | 959 /// identities, if any, are exempted from logging. |
| 968 * identities, if any, are exempted from logging. | 960 /// An AuditConfig must have one or more AuditLogConfigs. |
| 969 * An AuditConfig must have one or more AuditLogConfigs. | 961 /// |
| 970 * | 962 /// If there are AuditConfigs for both `allServices` and a specific service, |
| 971 * If there are AuditConfigs for both `allServices` and a specific service, | 963 /// the union of the two AuditConfigs is used for that service: the log_types |
| 972 * the union of the two AuditConfigs is used for that service: the log_types | 964 /// specified in each AuditConfig are enabled, and the exempted_members in each |
| 973 * specified in each AuditConfig are enabled, and the exempted_members in each | 965 /// AuditConfig are exempted. |
| 974 * AuditConfig are exempted. | 966 /// |
| 975 * | 967 /// Example Policy with multiple AuditConfigs: |
| 976 * Example Policy with multiple AuditConfigs: | 968 /// |
| 977 * | 969 /// { |
| 978 * { | 970 /// "audit_configs": [ |
| 979 * "audit_configs": [ | 971 /// { |
| 980 * { | 972 /// "service": "allServices" |
| 981 * "service": "allServices" | 973 /// "audit_log_configs": [ |
| 982 * "audit_log_configs": [ | 974 /// { |
| 983 * { | 975 /// "log_type": "DATA_READ", |
| 984 * "log_type": "DATA_READ", | 976 /// "exempted_members": [ |
| 985 * "exempted_members": [ | 977 /// "user:foo@gmail.com" |
| 986 * "user:foo@gmail.com" | 978 /// ] |
| 987 * ] | 979 /// }, |
| 988 * }, | 980 /// { |
| 989 * { | 981 /// "log_type": "DATA_WRITE", |
| 990 * "log_type": "DATA_WRITE", | 982 /// }, |
| 991 * }, | 983 /// { |
| 992 * { | 984 /// "log_type": "ADMIN_READ", |
| 993 * "log_type": "ADMIN_READ", | 985 /// } |
| 994 * } | 986 /// ] |
| 995 * ] | 987 /// }, |
| 996 * }, | 988 /// { |
| 997 * { | 989 /// "service": "fooservice.googleapis.com" |
| 998 * "service": "fooservice.googleapis.com" | 990 /// "audit_log_configs": [ |
| 999 * "audit_log_configs": [ | 991 /// { |
| 1000 * { | 992 /// "log_type": "DATA_READ", |
| 1001 * "log_type": "DATA_READ", | 993 /// }, |
| 1002 * }, | 994 /// { |
| 1003 * { | 995 /// "log_type": "DATA_WRITE", |
| 1004 * "log_type": "DATA_WRITE", | 996 /// "exempted_members": [ |
| 1005 * "exempted_members": [ | 997 /// "user:bar@gmail.com" |
| 1006 * "user:bar@gmail.com" | 998 /// ] |
| 1007 * ] | 999 /// } |
| 1008 * } | 1000 /// ] |
| 1009 * ] | 1001 /// } |
| 1010 * } | 1002 /// ] |
| 1011 * ] | 1003 /// } |
| 1012 * } | 1004 /// |
| 1013 * | 1005 /// For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ |
| 1014 * For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ | 1006 /// logging. It also exempts foo@gmail.com from DATA_READ logging, and |
| 1015 * logging. It also exempts foo@gmail.com from DATA_READ logging, and | 1007 /// bar@gmail.com from DATA_WRITE logging. |
| 1016 * bar@gmail.com from DATA_WRITE logging. | |
| 1017 */ | |
| 1018 class AuditConfig { | 1008 class AuditConfig { |
| 1019 /** | 1009 /// The configuration for logging of each type of permission. |
| 1020 * The configuration for logging of each type of permission. | 1010 /// Next ID: 4 |
| 1021 * Next ID: 4 | |
| 1022 */ | |
| 1023 core.List<AuditLogConfig> auditLogConfigs; | 1011 core.List<AuditLogConfig> auditLogConfigs; |
| 1024 /** | 1012 |
| 1025 * Specifies a service that will be enabled for audit logging. | 1013 /// Specifies a service that will be enabled for audit logging. |
| 1026 * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. | 1014 /// For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. |
| 1027 * `allServices` is a special value that covers all services. | 1015 /// `allServices` is a special value that covers all services. |
| 1028 */ | |
| 1029 core.String service; | 1016 core.String service; |
| 1030 | 1017 |
| 1031 AuditConfig(); | 1018 AuditConfig(); |
| 1032 | 1019 |
| 1033 AuditConfig.fromJson(core.Map _json) { | 1020 AuditConfig.fromJson(core.Map _json) { |
| 1034 if (_json.containsKey("auditLogConfigs")) { | 1021 if (_json.containsKey("auditLogConfigs")) { |
| 1035 auditLogConfigs = _json["auditLogConfigs"].map((value) => new AuditLogConf
ig.fromJson(value)).toList(); | 1022 auditLogConfigs = _json["auditLogConfigs"] |
| 1023 .map((value) => new AuditLogConfig.fromJson(value)) |
| 1024 .toList(); |
| 1036 } | 1025 } |
| 1037 if (_json.containsKey("service")) { | 1026 if (_json.containsKey("service")) { |
| 1038 service = _json["service"]; | 1027 service = _json["service"]; |
| 1039 } | 1028 } |
| 1040 } | 1029 } |
| 1041 | 1030 |
| 1042 core.Map<core.String, core.Object> toJson() { | 1031 core.Map<core.String, core.Object> toJson() { |
| 1043 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1032 final core.Map<core.String, core.Object> _json = |
| 1033 new core.Map<core.String, core.Object>(); |
| 1044 if (auditLogConfigs != null) { | 1034 if (auditLogConfigs != null) { |
| 1045 _json["auditLogConfigs"] = auditLogConfigs.map((value) => (value).toJson()
).toList(); | 1035 _json["auditLogConfigs"] = |
| 1036 auditLogConfigs.map((value) => (value).toJson()).toList(); |
| 1046 } | 1037 } |
| 1047 if (service != null) { | 1038 if (service != null) { |
| 1048 _json["service"] = service; | 1039 _json["service"] = service; |
| 1049 } | 1040 } |
| 1050 return _json; | 1041 return _json; |
| 1051 } | 1042 } |
| 1052 } | 1043 } |
| 1053 | 1044 |
| 1054 /** | 1045 /// Provides the configuration for logging a type of permissions. |
| 1055 * Provides the configuration for logging a type of permissions. | 1046 /// Example: |
| 1056 * Example: | 1047 /// |
| 1057 * | 1048 /// { |
| 1058 * { | 1049 /// "audit_log_configs": [ |
| 1059 * "audit_log_configs": [ | 1050 /// { |
| 1060 * { | 1051 /// "log_type": "DATA_READ", |
| 1061 * "log_type": "DATA_READ", | 1052 /// "exempted_members": [ |
| 1062 * "exempted_members": [ | 1053 /// "user:foo@gmail.com" |
| 1063 * "user:foo@gmail.com" | 1054 /// ] |
| 1064 * ] | 1055 /// }, |
| 1065 * }, | 1056 /// { |
| 1066 * { | 1057 /// "log_type": "DATA_WRITE", |
| 1067 * "log_type": "DATA_WRITE", | 1058 /// } |
| 1068 * } | 1059 /// ] |
| 1069 * ] | 1060 /// } |
| 1070 * } | 1061 /// |
| 1071 * | 1062 /// This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting |
| 1072 * This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting | 1063 /// foo@gmail.com from DATA_READ logging. |
| 1073 * foo@gmail.com from DATA_READ logging. | |
| 1074 */ | |
| 1075 class AuditLogConfig { | 1064 class AuditLogConfig { |
| 1076 /** | 1065 /// Specifies the identities that do not cause logging for this type of |
| 1077 * Specifies the identities that do not cause logging for this type of | 1066 /// permission. |
| 1078 * permission. | 1067 /// Follows the same format of Binding.members. |
| 1079 * Follows the same format of Binding.members. | |
| 1080 */ | |
| 1081 core.List<core.String> exemptedMembers; | 1068 core.List<core.String> exemptedMembers; |
| 1082 /** | 1069 |
| 1083 * The log type that this config enables. | 1070 /// The log type that this config enables. |
| 1084 * Possible string values are: | 1071 /// Possible string values are: |
| 1085 * - "LOG_TYPE_UNSPECIFIED" : Default case. Should never be this. | 1072 /// - "LOG_TYPE_UNSPECIFIED" : Default case. Should never be this. |
| 1086 * - "ADMIN_READ" : Admin reads. Example: CloudIAM getIamPolicy | 1073 /// - "ADMIN_READ" : Admin reads. Example: CloudIAM getIamPolicy |
| 1087 * - "DATA_WRITE" : Data writes. Example: CloudSQL Users create | 1074 /// - "DATA_WRITE" : Data writes. Example: CloudSQL Users create |
| 1088 * - "DATA_READ" : Data reads. Example: CloudSQL Users list | 1075 /// - "DATA_READ" : Data reads. Example: CloudSQL Users list |
| 1089 */ | |
| 1090 core.String logType; | 1076 core.String logType; |
| 1091 | 1077 |
| 1092 AuditLogConfig(); | 1078 AuditLogConfig(); |
| 1093 | 1079 |
| 1094 AuditLogConfig.fromJson(core.Map _json) { | 1080 AuditLogConfig.fromJson(core.Map _json) { |
| 1095 if (_json.containsKey("exemptedMembers")) { | 1081 if (_json.containsKey("exemptedMembers")) { |
| 1096 exemptedMembers = _json["exemptedMembers"]; | 1082 exemptedMembers = _json["exemptedMembers"]; |
| 1097 } | 1083 } |
| 1098 if (_json.containsKey("logType")) { | 1084 if (_json.containsKey("logType")) { |
| 1099 logType = _json["logType"]; | 1085 logType = _json["logType"]; |
| 1100 } | 1086 } |
| 1101 } | 1087 } |
| 1102 | 1088 |
| 1103 core.Map<core.String, core.Object> toJson() { | 1089 core.Map<core.String, core.Object> toJson() { |
| 1104 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1090 final core.Map<core.String, core.Object> _json = |
| 1091 new core.Map<core.String, core.Object>(); |
| 1105 if (exemptedMembers != null) { | 1092 if (exemptedMembers != null) { |
| 1106 _json["exemptedMembers"] = exemptedMembers; | 1093 _json["exemptedMembers"] = exemptedMembers; |
| 1107 } | 1094 } |
| 1108 if (logType != null) { | 1095 if (logType != null) { |
| 1109 _json["logType"] = logType; | 1096 _json["logType"] = logType; |
| 1110 } | 1097 } |
| 1111 return _json; | 1098 return _json; |
| 1112 } | 1099 } |
| 1113 } | 1100 } |
| 1114 | 1101 |
| 1115 /** Associates `members` with a `role`. */ | 1102 /// Associates `members` with a `role`. |
| 1116 class Binding { | 1103 class Binding { |
| 1117 /** | 1104 /// Specifies the identities requesting access for a Cloud Platform resource. |
| 1118 * Specifies the identities requesting access for a Cloud Platform resource. | 1105 /// `members` can have the following values: |
| 1119 * `members` can have the following values: | 1106 /// |
| 1120 * | 1107 /// * `allUsers`: A special identifier that represents anyone who is |
| 1121 * * `allUsers`: A special identifier that represents anyone who is | 1108 /// on the internet; with or without a Google account. |
| 1122 * on the internet; with or without a Google account. | 1109 /// |
| 1123 * | 1110 /// * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 1124 * * `allAuthenticatedUsers`: A special identifier that represents anyone | 1111 /// who is authenticated with a Google account or a service account. |
| 1125 * who is authenticated with a Google account or a service account. | 1112 /// |
| 1126 * | 1113 /// * `user:{emailid}`: An email address that represents a specific Google |
| 1127 * * `user:{emailid}`: An email address that represents a specific Google | 1114 /// account. For example, `alice@gmail.com` or `joe@example.com`. |
| 1128 * account. For example, `alice@gmail.com` or `joe@example.com`. | 1115 /// |
| 1129 * | 1116 /// |
| 1130 * | 1117 /// * `serviceAccount:{emailid}`: An email address that represents a service |
| 1131 * * `serviceAccount:{emailid}`: An email address that represents a service | 1118 /// account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 1132 * account. For example, `my-other-app@appspot.gserviceaccount.com`. | 1119 /// |
| 1133 * | 1120 /// * `group:{emailid}`: An email address that represents a Google group. |
| 1134 * * `group:{emailid}`: An email address that represents a Google group. | 1121 /// For example, `admins@example.com`. |
| 1135 * For example, `admins@example.com`. | 1122 /// |
| 1136 * | 1123 /// |
| 1137 * | 1124 /// * `domain:{domain}`: A Google Apps domain name that represents all the |
| 1138 * * `domain:{domain}`: A Google Apps domain name that represents all the | 1125 /// users of that domain. For example, `google.com` or `example.com`. |
| 1139 * users of that domain. For example, `google.com` or `example.com`. | |
| 1140 */ | |
| 1141 core.List<core.String> members; | 1126 core.List<core.String> members; |
| 1142 /** | 1127 |
| 1143 * Role that is assigned to `members`. | 1128 /// Role that is assigned to `members`. |
| 1144 * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. | 1129 /// For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
| 1145 * Required | 1130 /// Required |
| 1146 */ | |
| 1147 core.String role; | 1131 core.String role; |
| 1148 | 1132 |
| 1149 Binding(); | 1133 Binding(); |
| 1150 | 1134 |
| 1151 Binding.fromJson(core.Map _json) { | 1135 Binding.fromJson(core.Map _json) { |
| 1152 if (_json.containsKey("members")) { | 1136 if (_json.containsKey("members")) { |
| 1153 members = _json["members"]; | 1137 members = _json["members"]; |
| 1154 } | 1138 } |
| 1155 if (_json.containsKey("role")) { | 1139 if (_json.containsKey("role")) { |
| 1156 role = _json["role"]; | 1140 role = _json["role"]; |
| 1157 } | 1141 } |
| 1158 } | 1142 } |
| 1159 | 1143 |
| 1160 core.Map<core.String, core.Object> toJson() { | 1144 core.Map<core.String, core.Object> toJson() { |
| 1161 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1145 final core.Map<core.String, core.Object> _json = |
| 1146 new core.Map<core.String, core.Object>(); |
| 1162 if (members != null) { | 1147 if (members != null) { |
| 1163 _json["members"] = members; | 1148 _json["members"] = members; |
| 1164 } | 1149 } |
| 1165 if (role != null) { | 1150 if (role != null) { |
| 1166 _json["role"] = role; | 1151 _json["role"] = role; |
| 1167 } | 1152 } |
| 1168 return _json; | 1153 return _json; |
| 1169 } | 1154 } |
| 1170 } | 1155 } |
| 1171 | 1156 |
| 1172 /** | 1157 /// A generic empty message that you can re-use to avoid defining duplicated |
| 1173 * A generic empty message that you can re-use to avoid defining duplicated | 1158 /// empty messages in your APIs. A typical example is to use it as the request |
| 1174 * empty messages in your APIs. A typical example is to use it as the request | 1159 /// or the response type of an API method. For instance: |
| 1175 * or the response type of an API method. For instance: | 1160 /// |
| 1176 * | 1161 /// service Foo { |
| 1177 * service Foo { | 1162 /// rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); |
| 1178 * rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); | 1163 /// } |
| 1179 * } | 1164 /// |
| 1180 * | 1165 /// The JSON representation for `Empty` is empty JSON object `{}`. |
| 1181 * The JSON representation for `Empty` is empty JSON object `{}`. | |
| 1182 */ | |
| 1183 class Empty { | 1166 class Empty { |
| 1184 | |
| 1185 Empty(); | 1167 Empty(); |
| 1186 | 1168 |
| 1187 Empty.fromJson(core.Map _json) { | 1169 Empty.fromJson(core.Map _json) {} |
| 1188 } | |
| 1189 | 1170 |
| 1190 core.Map<core.String, core.Object> toJson() { | 1171 core.Map<core.String, core.Object> toJson() { |
| 1191 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1172 final core.Map<core.String, core.Object> _json = |
| 1173 new core.Map<core.String, core.Object>(); |
| 1192 return _json; | 1174 return _json; |
| 1193 } | 1175 } |
| 1194 } | 1176 } |
| 1195 | 1177 |
| 1196 /** Metadata describing a long running folder operation */ | 1178 /// Metadata describing a long running folder operation |
| 1197 class FolderOperation { | 1179 class FolderOperation { |
| 1198 /** | 1180 /// The resource name of the folder or organization we are either creating |
| 1199 * The resource name of the folder or organization we are either creating | 1181 /// the folder under or moving the folder to. |
| 1200 * the folder under or moving the folder to. | |
| 1201 */ | |
| 1202 core.String destinationParent; | 1182 core.String destinationParent; |
| 1203 /** The display name of the folder. */ | 1183 |
| 1184 /// The display name of the folder. |
| 1204 core.String displayName; | 1185 core.String displayName; |
| 1205 /** | 1186 |
| 1206 * The type of this operation. | 1187 /// The type of this operation. |
| 1207 * Possible string values are: | 1188 /// Possible string values are: |
| 1208 * - "OPERATION_TYPE_UNSPECIFIED" : Operation type not specified. | 1189 /// - "OPERATION_TYPE_UNSPECIFIED" : Operation type not specified. |
| 1209 * - "CREATE" : A create folder operation. | 1190 /// - "CREATE" : A create folder operation. |
| 1210 * - "MOVE" : A move folder operation. | 1191 /// - "MOVE" : A move folder operation. |
| 1211 */ | |
| 1212 core.String operationType; | 1192 core.String operationType; |
| 1213 /** | 1193 |
| 1214 * The resource name of the folder's parent. | 1194 /// The resource name of the folder's parent. |
| 1215 * Only applicable when the operation_type is MOVE. | 1195 /// Only applicable when the operation_type is MOVE. |
| 1216 */ | |
| 1217 core.String sourceParent; | 1196 core.String sourceParent; |
| 1218 | 1197 |
| 1219 FolderOperation(); | 1198 FolderOperation(); |
| 1220 | 1199 |
| 1221 FolderOperation.fromJson(core.Map _json) { | 1200 FolderOperation.fromJson(core.Map _json) { |
| 1222 if (_json.containsKey("destinationParent")) { | 1201 if (_json.containsKey("destinationParent")) { |
| 1223 destinationParent = _json["destinationParent"]; | 1202 destinationParent = _json["destinationParent"]; |
| 1224 } | 1203 } |
| 1225 if (_json.containsKey("displayName")) { | 1204 if (_json.containsKey("displayName")) { |
| 1226 displayName = _json["displayName"]; | 1205 displayName = _json["displayName"]; |
| 1227 } | 1206 } |
| 1228 if (_json.containsKey("operationType")) { | 1207 if (_json.containsKey("operationType")) { |
| 1229 operationType = _json["operationType"]; | 1208 operationType = _json["operationType"]; |
| 1230 } | 1209 } |
| 1231 if (_json.containsKey("sourceParent")) { | 1210 if (_json.containsKey("sourceParent")) { |
| 1232 sourceParent = _json["sourceParent"]; | 1211 sourceParent = _json["sourceParent"]; |
| 1233 } | 1212 } |
| 1234 } | 1213 } |
| 1235 | 1214 |
| 1236 core.Map<core.String, core.Object> toJson() { | 1215 core.Map<core.String, core.Object> toJson() { |
| 1237 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1216 final core.Map<core.String, core.Object> _json = |
| 1217 new core.Map<core.String, core.Object>(); |
| 1238 if (destinationParent != null) { | 1218 if (destinationParent != null) { |
| 1239 _json["destinationParent"] = destinationParent; | 1219 _json["destinationParent"] = destinationParent; |
| 1240 } | 1220 } |
| 1241 if (displayName != null) { | 1221 if (displayName != null) { |
| 1242 _json["displayName"] = displayName; | 1222 _json["displayName"] = displayName; |
| 1243 } | 1223 } |
| 1244 if (operationType != null) { | 1224 if (operationType != null) { |
| 1245 _json["operationType"] = operationType; | 1225 _json["operationType"] = operationType; |
| 1246 } | 1226 } |
| 1247 if (sourceParent != null) { | 1227 if (sourceParent != null) { |
| 1248 _json["sourceParent"] = sourceParent; | 1228 _json["sourceParent"] = sourceParent; |
| 1249 } | 1229 } |
| 1250 return _json; | 1230 return _json; |
| 1251 } | 1231 } |
| 1252 } | 1232 } |
| 1253 | 1233 |
| 1254 /** A classification of the Folder Operation error. */ | 1234 /// A classification of the Folder Operation error. |
| 1255 class FolderOperationError { | 1235 class FolderOperationError { |
| 1256 /** | 1236 /// The type of operation error experienced. |
| 1257 * The type of operation error experienced. | 1237 /// Possible string values are: |
| 1258 * Possible string values are: | 1238 /// - "ERROR_TYPE_UNSPECIFIED" : The error type was unrecognized or |
| 1259 * - "ERROR_TYPE_UNSPECIFIED" : The error type was unrecognized or | 1239 /// unspecified. |
| 1260 * unspecified. | 1240 /// - "ACTIVE_FOLDER_HEIGHT_VIOLATION" : The attempted action would violate |
| 1261 * - "ACTIVE_FOLDER_HEIGHT_VIOLATION" : The attempted action would violate the | 1241 /// the max folder depth constraint. |
| 1262 * max folder depth constraint. | 1242 /// - "MAX_CHILD_FOLDERS_VIOLATION" : The attempted action would violate the |
| 1263 * - "MAX_CHILD_FOLDERS_VIOLATION" : The attempted action would violate the | 1243 /// max child folders constraint. |
| 1264 * max child folders constraint. | 1244 /// - "FOLDER_NAME_UNIQUENESS_VIOLATION" : The attempted action would violate |
| 1265 * - "FOLDER_NAME_UNIQUENESS_VIOLATION" : The attempted action would violate | 1245 /// the locally-unique folder |
| 1266 * the locally-unique folder | 1246 /// display_name constraint. |
| 1267 * display_name constraint. | 1247 /// - "RESOURCE_DELETED_VIOLATION" : The resource being moved has been |
| 1268 * - "RESOURCE_DELETED_VIOLATION" : The resource being moved has been deleted. | 1248 /// deleted. |
| 1269 * - "PARENT_DELETED_VIOLATION" : The resource a folder was being added to has | 1249 /// - "PARENT_DELETED_VIOLATION" : The resource a folder was being added to |
| 1270 * been deleted. | 1250 /// has been deleted. |
| 1271 * - "CYCLE_INTRODUCED_VIOLATION" : The attempted action would introduce cycle | 1251 /// - "CYCLE_INTRODUCED_VIOLATION" : The attempted action would introduce |
| 1272 * in resource path. | 1252 /// cycle in resource path. |
| 1273 * - "FOLDER_BEING_MOVED_VIOLATION" : The attempted action would move a folder | 1253 /// - "FOLDER_BEING_MOVED_VIOLATION" : The attempted action would move a |
| 1274 * that is already being moved. | 1254 /// folder that is already being moved. |
| 1275 * - "FOLDER_TO_DELETE_NON_EMPTY_VIOLATION" : The folder the caller is trying | 1255 /// - "FOLDER_TO_DELETE_NON_EMPTY_VIOLATION" : The folder the caller is |
| 1276 * to delete contains active resources. | 1256 /// trying to delete contains active resources. |
| 1277 * - "DELETED_FOLDER_HEIGHT_VIOLATION" : The attempted action would violate | 1257 /// - "DELETED_FOLDER_HEIGHT_VIOLATION" : The attempted action would violate |
| 1278 * the max deleted folder depth | 1258 /// the max deleted folder depth |
| 1279 * constraint. | 1259 /// constraint. |
| 1280 */ | |
| 1281 core.String errorMessageId; | 1260 core.String errorMessageId; |
| 1282 | 1261 |
| 1283 FolderOperationError(); | 1262 FolderOperationError(); |
| 1284 | 1263 |
| 1285 FolderOperationError.fromJson(core.Map _json) { | 1264 FolderOperationError.fromJson(core.Map _json) { |
| 1286 if (_json.containsKey("errorMessageId")) { | 1265 if (_json.containsKey("errorMessageId")) { |
| 1287 errorMessageId = _json["errorMessageId"]; | 1266 errorMessageId = _json["errorMessageId"]; |
| 1288 } | 1267 } |
| 1289 } | 1268 } |
| 1290 | 1269 |
| 1291 core.Map<core.String, core.Object> toJson() { | 1270 core.Map<core.String, core.Object> toJson() { |
| 1292 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1271 final core.Map<core.String, core.Object> _json = |
| 1272 new core.Map<core.String, core.Object>(); |
| 1293 if (errorMessageId != null) { | 1273 if (errorMessageId != null) { |
| 1294 _json["errorMessageId"] = errorMessageId; | 1274 _json["errorMessageId"] = errorMessageId; |
| 1295 } | 1275 } |
| 1296 return _json; | 1276 return _json; |
| 1297 } | 1277 } |
| 1298 } | 1278 } |
| 1299 | 1279 |
| 1300 /** | 1280 /// The request sent to the |
| 1301 * The request sent to the | 1281 /// GetAncestry |
| 1302 * GetAncestry | 1282 /// method. |
| 1303 * method. | |
| 1304 */ | |
| 1305 class GetAncestryRequest { | 1283 class GetAncestryRequest { |
| 1306 | |
| 1307 GetAncestryRequest(); | 1284 GetAncestryRequest(); |
| 1308 | 1285 |
| 1309 GetAncestryRequest.fromJson(core.Map _json) { | 1286 GetAncestryRequest.fromJson(core.Map _json) {} |
| 1310 } | |
| 1311 | 1287 |
| 1312 core.Map<core.String, core.Object> toJson() { | 1288 core.Map<core.String, core.Object> toJson() { |
| 1313 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1289 final core.Map<core.String, core.Object> _json = |
| 1290 new core.Map<core.String, core.Object>(); |
| 1314 return _json; | 1291 return _json; |
| 1315 } | 1292 } |
| 1316 } | 1293 } |
| 1317 | 1294 |
| 1318 /** Response from the GetAncestry method. */ | 1295 /// Response from the GetAncestry method. |
| 1319 class GetAncestryResponse { | 1296 class GetAncestryResponse { |
| 1320 /** | 1297 /// Ancestors are ordered from bottom to top of the resource hierarchy. The |
| 1321 * Ancestors are ordered from bottom to top of the resource hierarchy. The | 1298 /// first ancestor is the project itself, followed by the project's parent, |
| 1322 * first ancestor is the project itself, followed by the project's parent, | 1299 /// etc. |
| 1323 * etc. | |
| 1324 */ | |
| 1325 core.List<Ancestor> ancestor; | 1300 core.List<Ancestor> ancestor; |
| 1326 | 1301 |
| 1327 GetAncestryResponse(); | 1302 GetAncestryResponse(); |
| 1328 | 1303 |
| 1329 GetAncestryResponse.fromJson(core.Map _json) { | 1304 GetAncestryResponse.fromJson(core.Map _json) { |
| 1330 if (_json.containsKey("ancestor")) { | 1305 if (_json.containsKey("ancestor")) { |
| 1331 ancestor = _json["ancestor"].map((value) => new Ancestor.fromJson(value)).
toList(); | 1306 ancestor = _json["ancestor"] |
| 1307 .map((value) => new Ancestor.fromJson(value)) |
| 1308 .toList(); |
| 1332 } | 1309 } |
| 1333 } | 1310 } |
| 1334 | 1311 |
| 1335 core.Map<core.String, core.Object> toJson() { | 1312 core.Map<core.String, core.Object> toJson() { |
| 1336 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1313 final core.Map<core.String, core.Object> _json = |
| 1314 new core.Map<core.String, core.Object>(); |
| 1337 if (ancestor != null) { | 1315 if (ancestor != null) { |
| 1338 _json["ancestor"] = ancestor.map((value) => (value).toJson()).toList(); | 1316 _json["ancestor"] = ancestor.map((value) => (value).toJson()).toList(); |
| 1339 } | 1317 } |
| 1340 return _json; | 1318 return _json; |
| 1341 } | 1319 } |
| 1342 } | 1320 } |
| 1343 | 1321 |
| 1344 /** Request message for `GetIamPolicy` method. */ | 1322 /// Request message for `GetIamPolicy` method. |
| 1345 class GetIamPolicyRequest { | 1323 class GetIamPolicyRequest { |
| 1346 | |
| 1347 GetIamPolicyRequest(); | 1324 GetIamPolicyRequest(); |
| 1348 | 1325 |
| 1349 GetIamPolicyRequest.fromJson(core.Map _json) { | 1326 GetIamPolicyRequest.fromJson(core.Map _json) {} |
| 1350 } | |
| 1351 | 1327 |
| 1352 core.Map<core.String, core.Object> toJson() { | 1328 core.Map<core.String, core.Object> toJson() { |
| 1353 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1329 final core.Map<core.String, core.Object> _json = |
| 1330 new core.Map<core.String, core.Object>(); |
| 1354 return _json; | 1331 return _json; |
| 1355 } | 1332 } |
| 1356 } | 1333 } |
| 1357 | 1334 |
| 1358 /** The response returned from the `ListOrganizations` method. */ | 1335 /// The response returned from the `ListOrganizations` method. |
| 1359 class ListOrganizationsResponse { | 1336 class ListOrganizationsResponse { |
| 1360 /** | 1337 /// A pagination token to be used to retrieve the next page of results. If |
| 1361 * A pagination token to be used to retrieve the next page of results. If the | 1338 /// the |
| 1362 * result is too large to fit within the page size specified in the request, | 1339 /// result is too large to fit within the page size specified in the request, |
| 1363 * this field will be set with a token that can be used to fetch the next page | 1340 /// this field will be set with a token that can be used to fetch the next |
| 1364 * of results. If this field is empty, it indicates that this response | 1341 /// page |
| 1365 * contains the last page of results. | 1342 /// of results. If this field is empty, it indicates that this response |
| 1366 */ | 1343 /// contains the last page of results. |
| 1367 core.String nextPageToken; | 1344 core.String nextPageToken; |
| 1368 /** | 1345 |
| 1369 * The list of Organizations that matched the list query, possibly paginated. | 1346 /// The list of Organizations that matched the list query, possibly |
| 1370 */ | 1347 /// paginated. |
| 1371 core.List<Organization> organizations; | 1348 core.List<Organization> organizations; |
| 1372 | 1349 |
| 1373 ListOrganizationsResponse(); | 1350 ListOrganizationsResponse(); |
| 1374 | 1351 |
| 1375 ListOrganizationsResponse.fromJson(core.Map _json) { | 1352 ListOrganizationsResponse.fromJson(core.Map _json) { |
| 1376 if (_json.containsKey("nextPageToken")) { | 1353 if (_json.containsKey("nextPageToken")) { |
| 1377 nextPageToken = _json["nextPageToken"]; | 1354 nextPageToken = _json["nextPageToken"]; |
| 1378 } | 1355 } |
| 1379 if (_json.containsKey("organizations")) { | 1356 if (_json.containsKey("organizations")) { |
| 1380 organizations = _json["organizations"].map((value) => new Organization.fro
mJson(value)).toList(); | 1357 organizations = _json["organizations"] |
| 1358 .map((value) => new Organization.fromJson(value)) |
| 1359 .toList(); |
| 1381 } | 1360 } |
| 1382 } | 1361 } |
| 1383 | 1362 |
| 1384 core.Map<core.String, core.Object> toJson() { | 1363 core.Map<core.String, core.Object> toJson() { |
| 1385 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1364 final core.Map<core.String, core.Object> _json = |
| 1365 new core.Map<core.String, core.Object>(); |
| 1386 if (nextPageToken != null) { | 1366 if (nextPageToken != null) { |
| 1387 _json["nextPageToken"] = nextPageToken; | 1367 _json["nextPageToken"] = nextPageToken; |
| 1388 } | 1368 } |
| 1389 if (organizations != null) { | 1369 if (organizations != null) { |
| 1390 _json["organizations"] = organizations.map((value) => (value).toJson()).to
List(); | 1370 _json["organizations"] = |
| 1371 organizations.map((value) => (value).toJson()).toList(); |
| 1391 } | 1372 } |
| 1392 return _json; | 1373 return _json; |
| 1393 } | 1374 } |
| 1394 } | 1375 } |
| 1395 | 1376 |
| 1396 /** | 1377 /// A page of the response received from the |
| 1397 * A page of the response received from the | 1378 /// ListProjects |
| 1398 * ListProjects | 1379 /// method. |
| 1399 * method. | 1380 /// |
| 1400 * | 1381 /// A paginated response where more pages are available has |
| 1401 * A paginated response where more pages are available has | 1382 /// `next_page_token` set. This token can be used in a subsequent request to |
| 1402 * `next_page_token` set. This token can be used in a subsequent request to | 1383 /// retrieve the next request page. |
| 1403 * retrieve the next request page. | |
| 1404 */ | |
| 1405 class ListProjectsResponse { | 1384 class ListProjectsResponse { |
| 1406 /** | 1385 /// Pagination token. |
| 1407 * Pagination token. | 1386 /// |
| 1408 * | 1387 /// If the result set is too large to fit in a single response, this token |
| 1409 * If the result set is too large to fit in a single response, this token | 1388 /// is returned. It encodes the position of the current result cursor. |
| 1410 * is returned. It encodes the position of the current result cursor. | 1389 /// Feeding this value into a new list request with the `page_token` |
| 1411 * Feeding this value into a new list request with the `page_token` parameter | 1390 /// parameter |
| 1412 * gives the next page of the results. | 1391 /// gives the next page of the results. |
| 1413 * | 1392 /// |
| 1414 * When `next_page_token` is not filled in, there is no next page and | 1393 /// When `next_page_token` is not filled in, there is no next page and |
| 1415 * the list returned is the last page in the result set. | 1394 /// the list returned is the last page in the result set. |
| 1416 * | 1395 /// |
| 1417 * Pagination tokens have a limited lifetime. | 1396 /// Pagination tokens have a limited lifetime. |
| 1418 */ | |
| 1419 core.String nextPageToken; | 1397 core.String nextPageToken; |
| 1420 /** | 1398 |
| 1421 * The list of Projects that matched the list filter. This list can | 1399 /// The list of Projects that matched the list filter. This list can |
| 1422 * be paginated. | 1400 /// be paginated. |
| 1423 */ | |
| 1424 core.List<Project> projects; | 1401 core.List<Project> projects; |
| 1425 | 1402 |
| 1426 ListProjectsResponse(); | 1403 ListProjectsResponse(); |
| 1427 | 1404 |
| 1428 ListProjectsResponse.fromJson(core.Map _json) { | 1405 ListProjectsResponse.fromJson(core.Map _json) { |
| 1429 if (_json.containsKey("nextPageToken")) { | 1406 if (_json.containsKey("nextPageToken")) { |
| 1430 nextPageToken = _json["nextPageToken"]; | 1407 nextPageToken = _json["nextPageToken"]; |
| 1431 } | 1408 } |
| 1432 if (_json.containsKey("projects")) { | 1409 if (_json.containsKey("projects")) { |
| 1433 projects = _json["projects"].map((value) => new Project.fromJson(value)).t
oList(); | 1410 projects = _json["projects"] |
| 1411 .map((value) => new Project.fromJson(value)) |
| 1412 .toList(); |
| 1434 } | 1413 } |
| 1435 } | 1414 } |
| 1436 | 1415 |
| 1437 core.Map<core.String, core.Object> toJson() { | 1416 core.Map<core.String, core.Object> toJson() { |
| 1438 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1417 final core.Map<core.String, core.Object> _json = |
| 1418 new core.Map<core.String, core.Object>(); |
| 1439 if (nextPageToken != null) { | 1419 if (nextPageToken != null) { |
| 1440 _json["nextPageToken"] = nextPageToken; | 1420 _json["nextPageToken"] = nextPageToken; |
| 1441 } | 1421 } |
| 1442 if (projects != null) { | 1422 if (projects != null) { |
| 1443 _json["projects"] = projects.map((value) => (value).toJson()).toList(); | 1423 _json["projects"] = projects.map((value) => (value).toJson()).toList(); |
| 1444 } | 1424 } |
| 1445 return _json; | 1425 return _json; |
| 1446 } | 1426 } |
| 1447 } | 1427 } |
| 1448 | 1428 |
| 1449 /** | 1429 /// The root node in the resource hierarchy to which a particular entity's |
| 1450 * The root node in the resource hierarchy to which a particular entity's | 1430 /// (e.g., company) resources belong. |
| 1451 * (e.g., company) resources belong. | |
| 1452 */ | |
| 1453 class Organization { | 1431 class Organization { |
| 1454 /** | 1432 /// Timestamp when the Organization was created. Assigned by the server. |
| 1455 * Timestamp when the Organization was created. Assigned by the server. | 1433 /// @OutputOnly |
| 1456 * @OutputOnly | |
| 1457 */ | |
| 1458 core.String creationTime; | 1434 core.String creationTime; |
| 1459 /** | 1435 |
| 1460 * A friendly string to be used to refer to the Organization in the UI. | 1436 /// A friendly string to be used to refer to the Organization in the UI. |
| 1461 * Assigned by the server, set to the primary domain of the G Suite | 1437 /// Assigned by the server, set to the primary domain of the G Suite |
| 1462 * customer that owns the organization. | 1438 /// customer that owns the organization. |
| 1463 * @OutputOnly | 1439 /// @OutputOnly |
| 1464 */ | |
| 1465 core.String displayName; | 1440 core.String displayName; |
| 1466 /** | 1441 |
| 1467 * The organization's current lifecycle state. Assigned by the server. | 1442 /// The organization's current lifecycle state. Assigned by the server. |
| 1468 * @OutputOnly | 1443 /// @OutputOnly |
| 1469 * Possible string values are: | 1444 /// Possible string values are: |
| 1470 * - "LIFECYCLE_STATE_UNSPECIFIED" : Unspecified state. This is only useful | 1445 /// - "LIFECYCLE_STATE_UNSPECIFIED" : Unspecified state. This is only useful |
| 1471 * for distinguishing unset values. | 1446 /// for distinguishing unset values. |
| 1472 * - "ACTIVE" : The normal and active state. | 1447 /// - "ACTIVE" : The normal and active state. |
| 1473 * - "DELETE_REQUESTED" : The organization has been marked for deletion by the | 1448 /// - "DELETE_REQUESTED" : The organization has been marked for deletion by |
| 1474 * user. | 1449 /// the user. |
| 1475 */ | |
| 1476 core.String lifecycleState; | 1450 core.String lifecycleState; |
| 1477 /** | 1451 |
| 1478 * Output Only. The resource name of the organization. This is the | 1452 /// Output Only. The resource name of the organization. This is the |
| 1479 * organization's relative path in the API. Its format is | 1453 /// organization's relative path in the API. Its format is |
| 1480 * "organizations/[organization_id]". For example, "organizations/1234". | 1454 /// "organizations/[organization_id]". For example, "organizations/1234". |
| 1481 */ | |
| 1482 core.String name; | 1455 core.String name; |
| 1483 /** | 1456 |
| 1484 * An immutable id for the Organization that is assigned on creation. This | 1457 /// An immutable id for the Organization that is assigned on creation. This |
| 1485 * should be omitted when creating a new Organization. | 1458 /// should be omitted when creating a new Organization. |
| 1486 * This field is read-only. | 1459 /// This field is read-only. |
| 1487 * This field is deprecated and will be removed in v1. Use name instead. | 1460 /// This field is deprecated and will be removed in v1. Use name instead. |
| 1488 */ | |
| 1489 core.String organizationId; | 1461 core.String organizationId; |
| 1490 /** | 1462 |
| 1491 * The owner of this Organization. The owner should be specified on | 1463 /// The owner of this Organization. The owner should be specified on |
| 1492 * creation. Once set, it cannot be changed. | 1464 /// creation. Once set, it cannot be changed. |
| 1493 * This field is required. | 1465 /// This field is required. |
| 1494 */ | |
| 1495 OrganizationOwner owner; | 1466 OrganizationOwner owner; |
| 1496 | 1467 |
| 1497 Organization(); | 1468 Organization(); |
| 1498 | 1469 |
| 1499 Organization.fromJson(core.Map _json) { | 1470 Organization.fromJson(core.Map _json) { |
| 1500 if (_json.containsKey("creationTime")) { | 1471 if (_json.containsKey("creationTime")) { |
| 1501 creationTime = _json["creationTime"]; | 1472 creationTime = _json["creationTime"]; |
| 1502 } | 1473 } |
| 1503 if (_json.containsKey("displayName")) { | 1474 if (_json.containsKey("displayName")) { |
| 1504 displayName = _json["displayName"]; | 1475 displayName = _json["displayName"]; |
| 1505 } | 1476 } |
| 1506 if (_json.containsKey("lifecycleState")) { | 1477 if (_json.containsKey("lifecycleState")) { |
| 1507 lifecycleState = _json["lifecycleState"]; | 1478 lifecycleState = _json["lifecycleState"]; |
| 1508 } | 1479 } |
| 1509 if (_json.containsKey("name")) { | 1480 if (_json.containsKey("name")) { |
| 1510 name = _json["name"]; | 1481 name = _json["name"]; |
| 1511 } | 1482 } |
| 1512 if (_json.containsKey("organizationId")) { | 1483 if (_json.containsKey("organizationId")) { |
| 1513 organizationId = _json["organizationId"]; | 1484 organizationId = _json["organizationId"]; |
| 1514 } | 1485 } |
| 1515 if (_json.containsKey("owner")) { | 1486 if (_json.containsKey("owner")) { |
| 1516 owner = new OrganizationOwner.fromJson(_json["owner"]); | 1487 owner = new OrganizationOwner.fromJson(_json["owner"]); |
| 1517 } | 1488 } |
| 1518 } | 1489 } |
| 1519 | 1490 |
| 1520 core.Map<core.String, core.Object> toJson() { | 1491 core.Map<core.String, core.Object> toJson() { |
| 1521 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1492 final core.Map<core.String, core.Object> _json = |
| 1493 new core.Map<core.String, core.Object>(); |
| 1522 if (creationTime != null) { | 1494 if (creationTime != null) { |
| 1523 _json["creationTime"] = creationTime; | 1495 _json["creationTime"] = creationTime; |
| 1524 } | 1496 } |
| 1525 if (displayName != null) { | 1497 if (displayName != null) { |
| 1526 _json["displayName"] = displayName; | 1498 _json["displayName"] = displayName; |
| 1527 } | 1499 } |
| 1528 if (lifecycleState != null) { | 1500 if (lifecycleState != null) { |
| 1529 _json["lifecycleState"] = lifecycleState; | 1501 _json["lifecycleState"] = lifecycleState; |
| 1530 } | 1502 } |
| 1531 if (name != null) { | 1503 if (name != null) { |
| 1532 _json["name"] = name; | 1504 _json["name"] = name; |
| 1533 } | 1505 } |
| 1534 if (organizationId != null) { | 1506 if (organizationId != null) { |
| 1535 _json["organizationId"] = organizationId; | 1507 _json["organizationId"] = organizationId; |
| 1536 } | 1508 } |
| 1537 if (owner != null) { | 1509 if (owner != null) { |
| 1538 _json["owner"] = (owner).toJson(); | 1510 _json["owner"] = (owner).toJson(); |
| 1539 } | 1511 } |
| 1540 return _json; | 1512 return _json; |
| 1541 } | 1513 } |
| 1542 } | 1514 } |
| 1543 | 1515 |
| 1544 /** | 1516 /// The entity that owns an Organization. The lifetime of the Organization and |
| 1545 * The entity that owns an Organization. The lifetime of the Organization and | 1517 /// all of its descendants are bound to the `OrganizationOwner`. If the |
| 1546 * all of its descendants are bound to the `OrganizationOwner`. If the | 1518 /// `OrganizationOwner` is deleted, the Organization and all its descendants |
| 1547 * `OrganizationOwner` is deleted, the Organization and all its descendants will | 1519 /// will |
| 1548 * be deleted. | 1520 /// be deleted. |
| 1549 */ | |
| 1550 class OrganizationOwner { | 1521 class OrganizationOwner { |
| 1551 /** The Google for Work customer id used in the Directory API. */ | 1522 /// The Google for Work customer id used in the Directory API. |
| 1552 core.String directoryCustomerId; | 1523 core.String directoryCustomerId; |
| 1553 | 1524 |
| 1554 OrganizationOwner(); | 1525 OrganizationOwner(); |
| 1555 | 1526 |
| 1556 OrganizationOwner.fromJson(core.Map _json) { | 1527 OrganizationOwner.fromJson(core.Map _json) { |
| 1557 if (_json.containsKey("directoryCustomerId")) { | 1528 if (_json.containsKey("directoryCustomerId")) { |
| 1558 directoryCustomerId = _json["directoryCustomerId"]; | 1529 directoryCustomerId = _json["directoryCustomerId"]; |
| 1559 } | 1530 } |
| 1560 } | 1531 } |
| 1561 | 1532 |
| 1562 core.Map<core.String, core.Object> toJson() { | 1533 core.Map<core.String, core.Object> toJson() { |
| 1563 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1534 final core.Map<core.String, core.Object> _json = |
| 1535 new core.Map<core.String, core.Object>(); |
| 1564 if (directoryCustomerId != null) { | 1536 if (directoryCustomerId != null) { |
| 1565 _json["directoryCustomerId"] = directoryCustomerId; | 1537 _json["directoryCustomerId"] = directoryCustomerId; |
| 1566 } | 1538 } |
| 1567 return _json; | 1539 return _json; |
| 1568 } | 1540 } |
| 1569 } | 1541 } |
| 1570 | 1542 |
| 1571 /** | 1543 /// Defines an Identity and Access Management (IAM) policy. It is used to |
| 1572 * Defines an Identity and Access Management (IAM) policy. It is used to | 1544 /// specify access control policies for Cloud Platform resources. |
| 1573 * specify access control policies for Cloud Platform resources. | 1545 /// |
| 1574 * | 1546 /// |
| 1575 * | 1547 /// A `Policy` consists of a list of `bindings`. A `Binding` binds a list of |
| 1576 * A `Policy` consists of a list of `bindings`. A `Binding` binds a list of | 1548 /// `members` to a `role`, where the members can be user accounts, Google |
| 1577 * `members` to a `role`, where the members can be user accounts, Google groups, | 1549 /// groups, |
| 1578 * Google domains, and service accounts. A `role` is a named list of permissions | 1550 /// Google domains, and service accounts. A `role` is a named list of |
| 1579 * defined by IAM. | 1551 /// permissions |
| 1580 * | 1552 /// defined by IAM. |
| 1581 * **Example** | 1553 /// |
| 1582 * | 1554 /// **Example** |
| 1583 * { | 1555 /// |
| 1584 * "bindings": [ | 1556 /// { |
| 1585 * { | 1557 /// "bindings": [ |
| 1586 * "role": "roles/owner", | 1558 /// { |
| 1587 * "members": [ | 1559 /// "role": "roles/owner", |
| 1588 * "user:mike@example.com", | 1560 /// "members": [ |
| 1589 * "group:admins@example.com", | 1561 /// "user:mike@example.com", |
| 1590 * "domain:google.com", | 1562 /// "group:admins@example.com", |
| 1591 * "serviceAccount:my-other-app@appspot.gserviceaccount.com", | 1563 /// "domain:google.com", |
| 1592 * ] | 1564 /// "serviceAccount:my-other-app@appspot.gserviceaccount.com", |
| 1593 * }, | 1565 /// ] |
| 1594 * { | 1566 /// }, |
| 1595 * "role": "roles/viewer", | 1567 /// { |
| 1596 * "members": ["user:sean@example.com"] | 1568 /// "role": "roles/viewer", |
| 1597 * } | 1569 /// "members": ["user:sean@example.com"] |
| 1598 * ] | 1570 /// } |
| 1599 * } | 1571 /// ] |
| 1600 * | 1572 /// } |
| 1601 * For a description of IAM and its features, see the | 1573 /// |
| 1602 * [IAM developer's guide](https://cloud.google.com/iam). | 1574 /// For a description of IAM and its features, see the |
| 1603 */ | 1575 /// [IAM developer's guide](https://cloud.google.com/iam). |
| 1604 class Policy { | 1576 class Policy { |
| 1605 /** Specifies cloud audit logging configuration for this policy. */ | 1577 /// Specifies cloud audit logging configuration for this policy. |
| 1606 core.List<AuditConfig> auditConfigs; | 1578 core.List<AuditConfig> auditConfigs; |
| 1607 /** | 1579 |
| 1608 * Associates a list of `members` to a `role`. | 1580 /// Associates a list of `members` to a `role`. |
| 1609 * `bindings` with no members will result in an error. | 1581 /// `bindings` with no members will result in an error. |
| 1610 */ | |
| 1611 core.List<Binding> bindings; | 1582 core.List<Binding> bindings; |
| 1612 /** | 1583 |
| 1613 * `etag` is used for optimistic concurrency control as a way to help | 1584 /// `etag` is used for optimistic concurrency control as a way to help |
| 1614 * prevent simultaneous updates of a policy from overwriting each other. | 1585 /// prevent simultaneous updates of a policy from overwriting each other. |
| 1615 * It is strongly suggested that systems make use of the `etag` in the | 1586 /// It is strongly suggested that systems make use of the `etag` in the |
| 1616 * read-modify-write cycle to perform policy updates in order to avoid race | 1587 /// read-modify-write cycle to perform policy updates in order to avoid race |
| 1617 * conditions: An `etag` is returned in the response to `getIamPolicy`, and | 1588 /// conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 1618 * systems are expected to put that etag in the request to `setIamPolicy` to | 1589 /// systems are expected to put that etag in the request to `setIamPolicy` to |
| 1619 * ensure that their change will be applied to the same version of the policy. | 1590 /// ensure that their change will be applied to the same version of the |
| 1620 * | 1591 /// policy. |
| 1621 * If no `etag` is provided in the call to `setIamPolicy`, then the existing | 1592 /// |
| 1622 * policy is overwritten blindly. | 1593 /// If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 1623 */ | 1594 /// policy is overwritten blindly. |
| 1624 core.String etag; | 1595 core.String etag; |
| 1625 core.List<core.int> get etagAsBytes { | 1596 core.List<core.int> get etagAsBytes { |
| 1626 return convert.BASE64.decode(etag); | 1597 return convert.BASE64.decode(etag); |
| 1627 } | 1598 } |
| 1628 | 1599 |
| 1629 void set etagAsBytes(core.List<core.int> _bytes) { | 1600 void set etagAsBytes(core.List<core.int> _bytes) { |
| 1630 etag = convert.BASE64.encode(_bytes).replaceAll("/", "_").replaceAll("+", "-
"); | 1601 etag = |
| 1602 convert.BASE64.encode(_bytes).replaceAll("/", "_").replaceAll("+", "-"); |
| 1631 } | 1603 } |
| 1632 /** Version of the `Policy`. The default version is 0. */ | 1604 |
| 1605 /// Version of the `Policy`. The default version is 0. |
| 1633 core.int version; | 1606 core.int version; |
| 1634 | 1607 |
| 1635 Policy(); | 1608 Policy(); |
| 1636 | 1609 |
| 1637 Policy.fromJson(core.Map _json) { | 1610 Policy.fromJson(core.Map _json) { |
| 1638 if (_json.containsKey("auditConfigs")) { | 1611 if (_json.containsKey("auditConfigs")) { |
| 1639 auditConfigs = _json["auditConfigs"].map((value) => new AuditConfig.fromJs
on(value)).toList(); | 1612 auditConfigs = _json["auditConfigs"] |
| 1613 .map((value) => new AuditConfig.fromJson(value)) |
| 1614 .toList(); |
| 1640 } | 1615 } |
| 1641 if (_json.containsKey("bindings")) { | 1616 if (_json.containsKey("bindings")) { |
| 1642 bindings = _json["bindings"].map((value) => new Binding.fromJson(value)).t
oList(); | 1617 bindings = _json["bindings"] |
| 1618 .map((value) => new Binding.fromJson(value)) |
| 1619 .toList(); |
| 1643 } | 1620 } |
| 1644 if (_json.containsKey("etag")) { | 1621 if (_json.containsKey("etag")) { |
| 1645 etag = _json["etag"]; | 1622 etag = _json["etag"]; |
| 1646 } | 1623 } |
| 1647 if (_json.containsKey("version")) { | 1624 if (_json.containsKey("version")) { |
| 1648 version = _json["version"]; | 1625 version = _json["version"]; |
| 1649 } | 1626 } |
| 1650 } | 1627 } |
| 1651 | 1628 |
| 1652 core.Map<core.String, core.Object> toJson() { | 1629 core.Map<core.String, core.Object> toJson() { |
| 1653 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1630 final core.Map<core.String, core.Object> _json = |
| 1631 new core.Map<core.String, core.Object>(); |
| 1654 if (auditConfigs != null) { | 1632 if (auditConfigs != null) { |
| 1655 _json["auditConfigs"] = auditConfigs.map((value) => (value).toJson()).toLi
st(); | 1633 _json["auditConfigs"] = |
| 1634 auditConfigs.map((value) => (value).toJson()).toList(); |
| 1656 } | 1635 } |
| 1657 if (bindings != null) { | 1636 if (bindings != null) { |
| 1658 _json["bindings"] = bindings.map((value) => (value).toJson()).toList(); | 1637 _json["bindings"] = bindings.map((value) => (value).toJson()).toList(); |
| 1659 } | 1638 } |
| 1660 if (etag != null) { | 1639 if (etag != null) { |
| 1661 _json["etag"] = etag; | 1640 _json["etag"] = etag; |
| 1662 } | 1641 } |
| 1663 if (version != null) { | 1642 if (version != null) { |
| 1664 _json["version"] = version; | 1643 _json["version"] = version; |
| 1665 } | 1644 } |
| 1666 return _json; | 1645 return _json; |
| 1667 } | 1646 } |
| 1668 } | 1647 } |
| 1669 | 1648 |
| 1670 /** | 1649 /// A Project is a high-level Google Cloud Platform entity. It is a |
| 1671 * A Project is a high-level Google Cloud Platform entity. It is a | 1650 /// container for ACLs, APIs, App Engine Apps, VMs, and other |
| 1672 * container for ACLs, APIs, App Engine Apps, VMs, and other | 1651 /// Google Cloud Platform resources. |
| 1673 * Google Cloud Platform resources. | |
| 1674 */ | |
| 1675 class Project { | 1652 class Project { |
| 1676 /** | 1653 /// Creation time. |
| 1677 * Creation time. | 1654 /// |
| 1678 * | 1655 /// Read-only. |
| 1679 * Read-only. | |
| 1680 */ | |
| 1681 core.String createTime; | 1656 core.String createTime; |
| 1682 /** | 1657 |
| 1683 * The labels associated with this Project. | 1658 /// The labels associated with this Project. |
| 1684 * | 1659 /// |
| 1685 * Label keys must be between 1 and 63 characters long and must conform | 1660 /// Label keys must be between 1 and 63 characters long and must conform |
| 1686 * to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. | 1661 /// to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. |
| 1687 * | 1662 /// |
| 1688 * Label values must be between 0 and 63 characters long and must conform | 1663 /// Label values must be between 0 and 63 characters long and must conform |
| 1689 * to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. | 1664 /// to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. |
| 1690 * | 1665 /// |
| 1691 * No more than 256 labels can be associated with a given resource. | 1666 /// No more than 256 labels can be associated with a given resource. |
| 1692 * | 1667 /// |
| 1693 * Clients should store labels in a representation such as JSON that does not | 1668 /// Clients should store labels in a representation such as JSON that does |
| 1694 * depend on specific characters being disallowed. | 1669 /// not |
| 1695 * | 1670 /// depend on specific characters being disallowed. |
| 1696 * Example: <code>"environment" : "dev"</code> | 1671 /// |
| 1697 * Read-write. | 1672 /// Example: <code>"environment" : "dev"</code> |
| 1698 */ | 1673 /// Read-write. |
| 1699 core.Map<core.String, core.String> labels; | 1674 core.Map<core.String, core.String> labels; |
| 1700 /** | 1675 |
| 1701 * The Project lifecycle state. | 1676 /// The Project lifecycle state. |
| 1702 * | 1677 /// |
| 1703 * Read-only. | 1678 /// Read-only. |
| 1704 * Possible string values are: | 1679 /// Possible string values are: |
| 1705 * - "LIFECYCLE_STATE_UNSPECIFIED" : Unspecified state. This is only | 1680 /// - "LIFECYCLE_STATE_UNSPECIFIED" : Unspecified state. This is only |
| 1706 * used/useful for distinguishing | 1681 /// used/useful for distinguishing |
| 1707 * unset values. | 1682 /// unset values. |
| 1708 * - "ACTIVE" : The normal and active state. | 1683 /// - "ACTIVE" : The normal and active state. |
| 1709 * - "DELETE_REQUESTED" : The project has been marked for deletion by the user | 1684 /// - "DELETE_REQUESTED" : The project has been marked for deletion by the |
| 1710 * (by invoking DeleteProject) | 1685 /// user |
| 1711 * or by the system (Google Cloud Platform). | 1686 /// (by invoking DeleteProject) |
| 1712 * This can generally be reversed by invoking UndeleteProject. | 1687 /// or by the system (Google Cloud Platform). |
| 1713 * - "DELETE_IN_PROGRESS" : This lifecycle state is no longer used and is not | 1688 /// This can generally be reversed by invoking UndeleteProject. |
| 1714 * returned by the API. | 1689 /// - "DELETE_IN_PROGRESS" : This lifecycle state is no longer used and is |
| 1715 */ | 1690 /// not returned by the API. |
| 1716 core.String lifecycleState; | 1691 core.String lifecycleState; |
| 1717 /** | 1692 |
| 1718 * The user-assigned display name of the Project. | 1693 /// The user-assigned display name of the Project. |
| 1719 * It must be 4 to 30 characters. | 1694 /// It must be 4 to 30 characters. |
| 1720 * Allowed characters are: lowercase and uppercase letters, numbers, | 1695 /// Allowed characters are: lowercase and uppercase letters, numbers, |
| 1721 * hyphen, single-quote, double-quote, space, and exclamation point. | 1696 /// hyphen, single-quote, double-quote, space, and exclamation point. |
| 1722 * | 1697 /// |
| 1723 * Example: <code>My Project</code> | 1698 /// Example: <code>My Project</code> |
| 1724 * Read-write. | 1699 /// Read-write. |
| 1725 */ | |
| 1726 core.String name; | 1700 core.String name; |
| 1727 /** | 1701 |
| 1728 * An optional reference to a parent Resource. | 1702 /// An optional reference to a parent Resource. |
| 1729 * | 1703 /// |
| 1730 * The only supported parent type is "organization". Once set, the parent | 1704 /// The only supported parent type is "organization". Once set, the parent |
| 1731 * cannot be modified. The `parent` can be set on creation or using the | 1705 /// cannot be modified. The `parent` can be set on creation or using the |
| 1732 * `UpdateProject` method; the end user must have the | 1706 /// `UpdateProject` method; the end user must have the |
| 1733 * `resourcemanager.projects.create` permission on the parent. | 1707 /// `resourcemanager.projects.create` permission on the parent. |
| 1734 * | 1708 /// |
| 1735 * Read-write. | 1709 /// Read-write. |
| 1736 */ | |
| 1737 ResourceId parent; | 1710 ResourceId parent; |
| 1738 /** | 1711 |
| 1739 * The unique, user-assigned ID of the Project. | 1712 /// The unique, user-assigned ID of the Project. |
| 1740 * It must be 6 to 30 lowercase letters, digits, or hyphens. | 1713 /// It must be 6 to 30 lowercase letters, digits, or hyphens. |
| 1741 * It must start with a letter. | 1714 /// It must start with a letter. |
| 1742 * Trailing hyphens are prohibited. | 1715 /// Trailing hyphens are prohibited. |
| 1743 * | 1716 /// |
| 1744 * Example: <code>tokyo-rain-123</code> | 1717 /// Example: <code>tokyo-rain-123</code> |
| 1745 * Read-only after creation. | 1718 /// Read-only after creation. |
| 1746 */ | |
| 1747 core.String projectId; | 1719 core.String projectId; |
| 1748 /** | 1720 |
| 1749 * The number uniquely identifying the project. | 1721 /// The number uniquely identifying the project. |
| 1750 * | 1722 /// |
| 1751 * Example: <code>415104041262</code> | 1723 /// Example: <code>415104041262</code> |
| 1752 * Read-only. | 1724 /// Read-only. |
| 1753 */ | |
| 1754 core.String projectNumber; | 1725 core.String projectNumber; |
| 1755 | 1726 |
| 1756 Project(); | 1727 Project(); |
| 1757 | 1728 |
| 1758 Project.fromJson(core.Map _json) { | 1729 Project.fromJson(core.Map _json) { |
| 1759 if (_json.containsKey("createTime")) { | 1730 if (_json.containsKey("createTime")) { |
| 1760 createTime = _json["createTime"]; | 1731 createTime = _json["createTime"]; |
| 1761 } | 1732 } |
| 1762 if (_json.containsKey("labels")) { | 1733 if (_json.containsKey("labels")) { |
| 1763 labels = _json["labels"]; | 1734 labels = _json["labels"]; |
| 1764 } | 1735 } |
| 1765 if (_json.containsKey("lifecycleState")) { | 1736 if (_json.containsKey("lifecycleState")) { |
| 1766 lifecycleState = _json["lifecycleState"]; | 1737 lifecycleState = _json["lifecycleState"]; |
| 1767 } | 1738 } |
| 1768 if (_json.containsKey("name")) { | 1739 if (_json.containsKey("name")) { |
| 1769 name = _json["name"]; | 1740 name = _json["name"]; |
| 1770 } | 1741 } |
| 1771 if (_json.containsKey("parent")) { | 1742 if (_json.containsKey("parent")) { |
| 1772 parent = new ResourceId.fromJson(_json["parent"]); | 1743 parent = new ResourceId.fromJson(_json["parent"]); |
| 1773 } | 1744 } |
| 1774 if (_json.containsKey("projectId")) { | 1745 if (_json.containsKey("projectId")) { |
| 1775 projectId = _json["projectId"]; | 1746 projectId = _json["projectId"]; |
| 1776 } | 1747 } |
| 1777 if (_json.containsKey("projectNumber")) { | 1748 if (_json.containsKey("projectNumber")) { |
| 1778 projectNumber = _json["projectNumber"]; | 1749 projectNumber = _json["projectNumber"]; |
| 1779 } | 1750 } |
| 1780 } | 1751 } |
| 1781 | 1752 |
| 1782 core.Map<core.String, core.Object> toJson() { | 1753 core.Map<core.String, core.Object> toJson() { |
| 1783 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1754 final core.Map<core.String, core.Object> _json = |
| 1755 new core.Map<core.String, core.Object>(); |
| 1784 if (createTime != null) { | 1756 if (createTime != null) { |
| 1785 _json["createTime"] = createTime; | 1757 _json["createTime"] = createTime; |
| 1786 } | 1758 } |
| 1787 if (labels != null) { | 1759 if (labels != null) { |
| 1788 _json["labels"] = labels; | 1760 _json["labels"] = labels; |
| 1789 } | 1761 } |
| 1790 if (lifecycleState != null) { | 1762 if (lifecycleState != null) { |
| 1791 _json["lifecycleState"] = lifecycleState; | 1763 _json["lifecycleState"] = lifecycleState; |
| 1792 } | 1764 } |
| 1793 if (name != null) { | 1765 if (name != null) { |
| 1794 _json["name"] = name; | 1766 _json["name"] = name; |
| 1795 } | 1767 } |
| 1796 if (parent != null) { | 1768 if (parent != null) { |
| 1797 _json["parent"] = (parent).toJson(); | 1769 _json["parent"] = (parent).toJson(); |
| 1798 } | 1770 } |
| 1799 if (projectId != null) { | 1771 if (projectId != null) { |
| 1800 _json["projectId"] = projectId; | 1772 _json["projectId"] = projectId; |
| 1801 } | 1773 } |
| 1802 if (projectNumber != null) { | 1774 if (projectNumber != null) { |
| 1803 _json["projectNumber"] = projectNumber; | 1775 _json["projectNumber"] = projectNumber; |
| 1804 } | 1776 } |
| 1805 return _json; | 1777 return _json; |
| 1806 } | 1778 } |
| 1807 } | 1779 } |
| 1808 | 1780 |
| 1809 /** | 1781 /// A status object which is used as the `metadata` field for the Operation |
| 1810 * A status object which is used as the `metadata` field for the Operation | 1782 /// returned by CreateProject. It provides insight for when significant phases |
| 1811 * returned by CreateProject. It provides insight for when significant phases of | 1783 /// of |
| 1812 * Project creation have completed. | 1784 /// Project creation have completed. |
| 1813 */ | |
| 1814 class ProjectCreationStatus { | 1785 class ProjectCreationStatus { |
| 1815 /** Creation time of the project creation workflow. */ | 1786 /// Creation time of the project creation workflow. |
| 1816 core.String createTime; | 1787 core.String createTime; |
| 1817 /** | 1788 |
| 1818 * True if the project can be retrieved using GetProject. No other operations | 1789 /// True if the project can be retrieved using GetProject. No other |
| 1819 * on the project are guaranteed to work until the project creation is | 1790 /// operations |
| 1820 * complete. | 1791 /// on the project are guaranteed to work until the project creation is |
| 1821 */ | 1792 /// complete. |
| 1822 core.bool gettable; | 1793 core.bool gettable; |
| 1823 /** True if the project creation process is complete. */ | 1794 |
| 1795 /// True if the project creation process is complete. |
| 1824 core.bool ready; | 1796 core.bool ready; |
| 1825 | 1797 |
| 1826 ProjectCreationStatus(); | 1798 ProjectCreationStatus(); |
| 1827 | 1799 |
| 1828 ProjectCreationStatus.fromJson(core.Map _json) { | 1800 ProjectCreationStatus.fromJson(core.Map _json) { |
| 1829 if (_json.containsKey("createTime")) { | 1801 if (_json.containsKey("createTime")) { |
| 1830 createTime = _json["createTime"]; | 1802 createTime = _json["createTime"]; |
| 1831 } | 1803 } |
| 1832 if (_json.containsKey("gettable")) { | 1804 if (_json.containsKey("gettable")) { |
| 1833 gettable = _json["gettable"]; | 1805 gettable = _json["gettable"]; |
| 1834 } | 1806 } |
| 1835 if (_json.containsKey("ready")) { | 1807 if (_json.containsKey("ready")) { |
| 1836 ready = _json["ready"]; | 1808 ready = _json["ready"]; |
| 1837 } | 1809 } |
| 1838 } | 1810 } |
| 1839 | 1811 |
| 1840 core.Map<core.String, core.Object> toJson() { | 1812 core.Map<core.String, core.Object> toJson() { |
| 1841 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1813 final core.Map<core.String, core.Object> _json = |
| 1814 new core.Map<core.String, core.Object>(); |
| 1842 if (createTime != null) { | 1815 if (createTime != null) { |
| 1843 _json["createTime"] = createTime; | 1816 _json["createTime"] = createTime; |
| 1844 } | 1817 } |
| 1845 if (gettable != null) { | 1818 if (gettable != null) { |
| 1846 _json["gettable"] = gettable; | 1819 _json["gettable"] = gettable; |
| 1847 } | 1820 } |
| 1848 if (ready != null) { | 1821 if (ready != null) { |
| 1849 _json["ready"] = ready; | 1822 _json["ready"] = ready; |
| 1850 } | 1823 } |
| 1851 return _json; | 1824 return _json; |
| 1852 } | 1825 } |
| 1853 } | 1826 } |
| 1854 | 1827 |
| 1855 /** | 1828 /// A container to reference an id for any resource type. A `resource` in |
| 1856 * A container to reference an id for any resource type. A `resource` in Google | 1829 /// Google |
| 1857 * Cloud Platform is a generic term for something you (a developer) may want to | 1830 /// Cloud Platform is a generic term for something you (a developer) may want |
| 1858 * interact with through one of our API's. Some examples are an App Engine app, | 1831 /// to |
| 1859 * a Compute Engine instance, a Cloud SQL database, and so on. | 1832 /// interact with through one of our API's. Some examples are an App Engine |
| 1860 */ | 1833 /// app, |
| 1834 /// a Compute Engine instance, a Cloud SQL database, and so on. |
| 1861 class ResourceId { | 1835 class ResourceId { |
| 1862 /** | 1836 /// Required field for the type-specific id. This should correspond to the id |
| 1863 * Required field for the type-specific id. This should correspond to the id | 1837 /// used in the type-specific API's. |
| 1864 * used in the type-specific API's. | |
| 1865 */ | |
| 1866 core.String id; | 1838 core.String id; |
| 1867 /** | 1839 |
| 1868 * Required field representing the resource type this id is for. | 1840 /// Required field representing the resource type this id is for. |
| 1869 * At present, the valid types are "project" and "organization". | 1841 /// At present, the valid types are "project", "folder", and "organization". |
| 1870 */ | |
| 1871 core.String type; | 1842 core.String type; |
| 1872 | 1843 |
| 1873 ResourceId(); | 1844 ResourceId(); |
| 1874 | 1845 |
| 1875 ResourceId.fromJson(core.Map _json) { | 1846 ResourceId.fromJson(core.Map _json) { |
| 1876 if (_json.containsKey("id")) { | 1847 if (_json.containsKey("id")) { |
| 1877 id = _json["id"]; | 1848 id = _json["id"]; |
| 1878 } | 1849 } |
| 1879 if (_json.containsKey("type")) { | 1850 if (_json.containsKey("type")) { |
| 1880 type = _json["type"]; | 1851 type = _json["type"]; |
| 1881 } | 1852 } |
| 1882 } | 1853 } |
| 1883 | 1854 |
| 1884 core.Map<core.String, core.Object> toJson() { | 1855 core.Map<core.String, core.Object> toJson() { |
| 1885 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1856 final core.Map<core.String, core.Object> _json = |
| 1857 new core.Map<core.String, core.Object>(); |
| 1886 if (id != null) { | 1858 if (id != null) { |
| 1887 _json["id"] = id; | 1859 _json["id"] = id; |
| 1888 } | 1860 } |
| 1889 if (type != null) { | 1861 if (type != null) { |
| 1890 _json["type"] = type; | 1862 _json["type"] = type; |
| 1891 } | 1863 } |
| 1892 return _json; | 1864 return _json; |
| 1893 } | 1865 } |
| 1894 } | 1866 } |
| 1895 | 1867 |
| 1896 /** Request message for `SetIamPolicy` method. */ | 1868 /// Request message for `SetIamPolicy` method. |
| 1897 class SetIamPolicyRequest { | 1869 class SetIamPolicyRequest { |
| 1898 /** | 1870 /// REQUIRED: The complete policy to be applied to the `resource`. The size |
| 1899 * REQUIRED: The complete policy to be applied to the `resource`. The size of | 1871 /// of |
| 1900 * the policy is limited to a few 10s of KB. An empty policy is a | 1872 /// the policy is limited to a few 10s of KB. An empty policy is a |
| 1901 * valid policy but certain Cloud Platform services (such as Projects) | 1873 /// valid policy but certain Cloud Platform services (such as Projects) |
| 1902 * might reject them. | 1874 /// might reject them. |
| 1903 */ | |
| 1904 Policy policy; | 1875 Policy policy; |
| 1905 /** | 1876 |
| 1906 * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only | 1877 /// OPTIONAL: A FieldMask specifying which fields of the policy to modify. |
| 1907 * the fields in the mask will be modified. If no mask is provided, the | 1878 /// Only |
| 1908 * following default mask is used: | 1879 /// the fields in the mask will be modified. If no mask is provided, the |
| 1909 * paths: "bindings, etag" | 1880 /// following default mask is used: |
| 1910 * This field is only used by Cloud IAM. | 1881 /// paths: "bindings, etag" |
| 1911 */ | 1882 /// This field is only used by Cloud IAM. |
| 1912 core.String updateMask; | 1883 core.String updateMask; |
| 1913 | 1884 |
| 1914 SetIamPolicyRequest(); | 1885 SetIamPolicyRequest(); |
| 1915 | 1886 |
| 1916 SetIamPolicyRequest.fromJson(core.Map _json) { | 1887 SetIamPolicyRequest.fromJson(core.Map _json) { |
| 1917 if (_json.containsKey("policy")) { | 1888 if (_json.containsKey("policy")) { |
| 1918 policy = new Policy.fromJson(_json["policy"]); | 1889 policy = new Policy.fromJson(_json["policy"]); |
| 1919 } | 1890 } |
| 1920 if (_json.containsKey("updateMask")) { | 1891 if (_json.containsKey("updateMask")) { |
| 1921 updateMask = _json["updateMask"]; | 1892 updateMask = _json["updateMask"]; |
| 1922 } | 1893 } |
| 1923 } | 1894 } |
| 1924 | 1895 |
| 1925 core.Map<core.String, core.Object> toJson() { | 1896 core.Map<core.String, core.Object> toJson() { |
| 1926 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1897 final core.Map<core.String, core.Object> _json = |
| 1898 new core.Map<core.String, core.Object>(); |
| 1927 if (policy != null) { | 1899 if (policy != null) { |
| 1928 _json["policy"] = (policy).toJson(); | 1900 _json["policy"] = (policy).toJson(); |
| 1929 } | 1901 } |
| 1930 if (updateMask != null) { | 1902 if (updateMask != null) { |
| 1931 _json["updateMask"] = updateMask; | 1903 _json["updateMask"] = updateMask; |
| 1932 } | 1904 } |
| 1933 return _json; | 1905 return _json; |
| 1934 } | 1906 } |
| 1935 } | 1907 } |
| 1936 | 1908 |
| 1937 /** Request message for `TestIamPermissions` method. */ | 1909 /// Request message for `TestIamPermissions` method. |
| 1938 class TestIamPermissionsRequest { | 1910 class TestIamPermissionsRequest { |
| 1939 /** | 1911 /// The set of permissions to check for the `resource`. Permissions with |
| 1940 * The set of permissions to check for the `resource`. Permissions with | 1912 /// wildcards (such as '*' or 'storage.*') are not allowed. For more |
| 1941 * wildcards (such as '*' or 'storage.*') are not allowed. For more | 1913 /// information see |
| 1942 * information see | 1914 /// [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
| 1943 * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). | |
| 1944 */ | |
| 1945 core.List<core.String> permissions; | 1915 core.List<core.String> permissions; |
| 1946 | 1916 |
| 1947 TestIamPermissionsRequest(); | 1917 TestIamPermissionsRequest(); |
| 1948 | 1918 |
| 1949 TestIamPermissionsRequest.fromJson(core.Map _json) { | 1919 TestIamPermissionsRequest.fromJson(core.Map _json) { |
| 1950 if (_json.containsKey("permissions")) { | 1920 if (_json.containsKey("permissions")) { |
| 1951 permissions = _json["permissions"]; | 1921 permissions = _json["permissions"]; |
| 1952 } | 1922 } |
| 1953 } | 1923 } |
| 1954 | 1924 |
| 1955 core.Map<core.String, core.Object> toJson() { | 1925 core.Map<core.String, core.Object> toJson() { |
| 1956 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1926 final core.Map<core.String, core.Object> _json = |
| 1927 new core.Map<core.String, core.Object>(); |
| 1957 if (permissions != null) { | 1928 if (permissions != null) { |
| 1958 _json["permissions"] = permissions; | 1929 _json["permissions"] = permissions; |
| 1959 } | 1930 } |
| 1960 return _json; | 1931 return _json; |
| 1961 } | 1932 } |
| 1962 } | 1933 } |
| 1963 | 1934 |
| 1964 /** Response message for `TestIamPermissions` method. */ | 1935 /// Response message for `TestIamPermissions` method. |
| 1965 class TestIamPermissionsResponse { | 1936 class TestIamPermissionsResponse { |
| 1966 /** | 1937 /// A subset of `TestPermissionsRequest.permissions` that the caller is |
| 1967 * A subset of `TestPermissionsRequest.permissions` that the caller is | 1938 /// allowed. |
| 1968 * allowed. | |
| 1969 */ | |
| 1970 core.List<core.String> permissions; | 1939 core.List<core.String> permissions; |
| 1971 | 1940 |
| 1972 TestIamPermissionsResponse(); | 1941 TestIamPermissionsResponse(); |
| 1973 | 1942 |
| 1974 TestIamPermissionsResponse.fromJson(core.Map _json) { | 1943 TestIamPermissionsResponse.fromJson(core.Map _json) { |
| 1975 if (_json.containsKey("permissions")) { | 1944 if (_json.containsKey("permissions")) { |
| 1976 permissions = _json["permissions"]; | 1945 permissions = _json["permissions"]; |
| 1977 } | 1946 } |
| 1978 } | 1947 } |
| 1979 | 1948 |
| 1980 core.Map<core.String, core.Object> toJson() { | 1949 core.Map<core.String, core.Object> toJson() { |
| 1981 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1950 final core.Map<core.String, core.Object> _json = |
| 1951 new core.Map<core.String, core.Object>(); |
| 1982 if (permissions != null) { | 1952 if (permissions != null) { |
| 1983 _json["permissions"] = permissions; | 1953 _json["permissions"] = permissions; |
| 1984 } | 1954 } |
| 1985 return _json; | 1955 return _json; |
| 1986 } | 1956 } |
| 1987 } | 1957 } |
| 1988 | 1958 |
| 1989 /** | 1959 /// The request sent to the UndeleteProject |
| 1990 * The request sent to the UndeleteProject | 1960 /// method. |
| 1991 * method. | |
| 1992 */ | |
| 1993 class UndeleteProjectRequest { | 1961 class UndeleteProjectRequest { |
| 1994 | |
| 1995 UndeleteProjectRequest(); | 1962 UndeleteProjectRequest(); |
| 1996 | 1963 |
| 1997 UndeleteProjectRequest.fromJson(core.Map _json) { | 1964 UndeleteProjectRequest.fromJson(core.Map _json) {} |
| 1998 } | |
| 1999 | 1965 |
| 2000 core.Map<core.String, core.Object> toJson() { | 1966 core.Map<core.String, core.Object> toJson() { |
| 2001 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1967 final core.Map<core.String, core.Object> _json = |
| 1968 new core.Map<core.String, core.Object>(); |
| 2002 return _json; | 1969 return _json; |
| 2003 } | 1970 } |
| 2004 } | 1971 } |
| OLD | NEW |