1 | <?php
|
---|
2 | /*
|
---|
3 | * Copyright 2014 Google Inc.
|
---|
4 | *
|
---|
5 | * Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
---|
6 | * use this file except in compliance with the License. You may obtain a copy of
|
---|
7 | * the License at
|
---|
8 | *
|
---|
9 | * http://www.apache.org/licenses/LICENSE-2.0
|
---|
10 | *
|
---|
11 | * Unless required by applicable law or agreed to in writing, software
|
---|
12 | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
---|
13 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
---|
14 | * License for the specific language governing permissions and limitations under
|
---|
15 | * the License.
|
---|
16 | */
|
---|
17 |
|
---|
18 | namespace Google\Service\CertificateAuthorityService\Resource;
|
---|
19 |
|
---|
20 | use Google\Service\CertificateAuthorityService\Policy;
|
---|
21 |
|
---|
22 | /**
|
---|
23 | * The "managedPkis" collection of methods.
|
---|
24 | * Typical usage is:
|
---|
25 | * <code>
|
---|
26 | * $privatecaService = new Google\Service\CertificateAuthorityService(...);
|
---|
27 | * $managedPkis = $privatecaService->managedPkis;
|
---|
28 | * </code>
|
---|
29 | */
|
---|
30 | class ProjectsLocationsManagedPkis extends \Google\Service\Resource
|
---|
31 | {
|
---|
32 | /**
|
---|
33 | * Gets the access control policy for a resource. Returns an empty policy if the
|
---|
34 | * resource exists and does not have a policy set. (managedPkis.getIamPolicy)
|
---|
35 | *
|
---|
36 | * @param string $resource REQUIRED: The resource for which the policy is being
|
---|
37 | * requested. See the operation documentation for the appropriate value for this
|
---|
38 | * field.
|
---|
39 | * @param array $optParams Optional parameters.
|
---|
40 | *
|
---|
41 | * @opt_param int options.requestedPolicyVersion Optional. The maximum policy
|
---|
42 | * version that will be used to format the policy. Valid values are 0, 1, and 3.
|
---|
43 | * Requests specifying an invalid value will be rejected. Requests for policies
|
---|
44 | * with any conditional role bindings must specify version 3. Policies with no
|
---|
45 | * conditional role bindings may specify any valid value or leave the field
|
---|
46 | * unset. The policy in the response might use the policy version that you
|
---|
47 | * specified, or it might use a lower policy version. For example, if you
|
---|
48 | * specify version 3, but the policy has no conditional role bindings, the
|
---|
49 | * response uses version 1. To learn which resources support conditions in their
|
---|
50 | * IAM policies, see the [IAM
|
---|
51 | * documentation](https://cloud.google.com/iam/help/conditions/resource-
|
---|
52 | * policies).
|
---|
53 | * @return Policy
|
---|
54 | */
|
---|
55 | public function getIamPolicy($resource, $optParams = [])
|
---|
56 | {
|
---|
57 | $params = ['resource' => $resource];
|
---|
58 | $params = array_merge($params, $optParams);
|
---|
59 | return $this->call('getIamPolicy', [$params], Policy::class);
|
---|
60 | }
|
---|
61 | }
|
---|
62 |
|
---|
63 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
64 | class_alias(ProjectsLocationsManagedPkis::class, 'Google_Service_CertificateAuthorityService_Resource_ProjectsLocationsManagedPkis');
|
---|