source: vendor/google/apiclient-services/src/AccessApproval/Resource/Organizations.php@ f9c482b

Last change on this file since f9c482b was f9c482b, checked in by Vlado 222039 <vlado.popovski@…>, 2 weeks ago

Upload new project files

  • Property mode set to 100644
File size: 4.9 KB
Line 
1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18namespace Google\Service\AccessApproval\Resource;
19
20use Google\Service\AccessApproval\AccessApprovalServiceAccount;
21use Google\Service\AccessApproval\AccessApprovalSettings;
22use Google\Service\AccessApproval\AccessapprovalEmpty;
23
24/**
25 * The "organizations" collection of methods.
26 * Typical usage is:
27 * <code>
28 * $accessapprovalService = new Google\Service\AccessApproval(...);
29 * $organizations = $accessapprovalService->organizations;
30 * </code>
31 */
32class Organizations extends \Google\Service\Resource
33{
34 /**
35 * Deletes the settings associated with a project, folder, or organization. This
36 * will have the effect of disabling Access Approval for the project, folder, or
37 * organization, but only if all ancestors also have Access Approval disabled.
38 * If Access Approval is enabled at a higher level of the hierarchy, then Access
39 * Approval will still be enabled at this level as the settings are inherited.
40 * (organizations.deleteAccessApprovalSettings)
41 *
42 * @param string $name Name of the AccessApprovalSettings to delete.
43 * @param array $optParams Optional parameters.
44 * @return AccessapprovalEmpty
45 * @throws \Google\Service\Exception
46 */
47 public function deleteAccessApprovalSettings($name, $optParams = [])
48 {
49 $params = ['name' => $name];
50 $params = array_merge($params, $optParams);
51 return $this->call('deleteAccessApprovalSettings', [$params], AccessapprovalEmpty::class);
52 }
53 /**
54 * Gets the settings associated with a project, folder, or organization.
55 * (organizations.getAccessApprovalSettings)
56 *
57 * @param string $name The name of the AccessApprovalSettings to retrieve.
58 * Format: "{projects|folders|organizations}/{id}/accessApprovalSettings"
59 * @param array $optParams Optional parameters.
60 * @return AccessApprovalSettings
61 * @throws \Google\Service\Exception
62 */
63 public function getAccessApprovalSettings($name, $optParams = [])
64 {
65 $params = ['name' => $name];
66 $params = array_merge($params, $optParams);
67 return $this->call('getAccessApprovalSettings', [$params], AccessApprovalSettings::class);
68 }
69 /**
70 * Retrieves the service account that is used by Access Approval to access KMS
71 * keys for signing approved approval requests.
72 * (organizations.getServiceAccount)
73 *
74 * @param string $name Name of the AccessApprovalServiceAccount to retrieve.
75 * @param array $optParams Optional parameters.
76 * @return AccessApprovalServiceAccount
77 * @throws \Google\Service\Exception
78 */
79 public function getServiceAccount($name, $optParams = [])
80 {
81 $params = ['name' => $name];
82 $params = array_merge($params, $optParams);
83 return $this->call('getServiceAccount', [$params], AccessApprovalServiceAccount::class);
84 }
85 /**
86 * Updates the settings associated with a project, folder, or organization.
87 * Settings to update are determined by the value of field_mask.
88 * (organizations.updateAccessApprovalSettings)
89 *
90 * @param string $name The resource name of the settings. Format is one of: *
91 * "projects/{project}/accessApprovalSettings" *
92 * "folders/{folder}/accessApprovalSettings" *
93 * "organizations/{organization}/accessApprovalSettings"
94 * @param AccessApprovalSettings $postBody
95 * @param array $optParams Optional parameters.
96 *
97 * @opt_param string updateMask The update mask applies to the settings. Only
98 * the top level fields of AccessApprovalSettings (notification_emails &
99 * enrolled_services) are supported. For each field, if it is included, the
100 * currently stored value will be entirely overwritten with the value of the
101 * field passed in this request. For the `FieldMask` definition, see
102 * https://developers.google.com/protocol-
103 * buffers/docs/reference/google.protobuf#fieldmask If this field is left unset,
104 * only the notification_emails field will be updated.
105 * @return AccessApprovalSettings
106 * @throws \Google\Service\Exception
107 */
108 public function updateAccessApprovalSettings($name, AccessApprovalSettings $postBody, $optParams = [])
109 {
110 $params = ['name' => $name, 'postBody' => $postBody];
111 $params = array_merge($params, $optParams);
112 return $this->call('updateAccessApprovalSettings', [$params], AccessApprovalSettings::class);
113 }
114}
115
116// Adding a class alias for backwards compatibility with the previous class name.
117class_alias(Organizations::class, 'Google_Service_AccessApproval_Resource_Organizations');
Note: See TracBrowser for help on using the repository browser.