* $cloudiotService = new Google\Service\CloudIot(...); * $groups = $cloudiotService->groups; * */ class ProjectsLocationsRegistriesGroups extends \Google\Service\Resource { /** * Gets the access control policy for a resource. Returns an empty policy if the * resource exists and does not have a policy set. (groups.getIamPolicy) * * @param string $resource REQUIRED: The resource for which the policy is being * requested. See the operation documentation for the appropriate value for this * field. * @param GetIamPolicyRequest $postBody * @param array $optParams Optional parameters. * @return Policy */ public function getIamPolicy($resource, GetIamPolicyRequest $postBody, $optParams = []) { $params = ['resource' => $resource, 'postBody' => $postBody]; $params = array_merge($params, $optParams); return $this->call('getIamPolicy', [$params], Policy::class); } /** * Sets the access control policy on the specified resource. Replaces any * existing policy. (groups.setIamPolicy) * * @param string $resource REQUIRED: The resource for which the policy is being * specified. See the operation documentation for the appropriate value for this * field. * @param SetIamPolicyRequest $postBody * @param array $optParams Optional parameters. * @return Policy */ public function setIamPolicy($resource, SetIamPolicyRequest $postBody, $optParams = []) { $params = ['resource' => $resource, 'postBody' => $postBody]; $params = array_merge($params, $optParams); return $this->call('setIamPolicy', [$params], Policy::class); } /** * Returns permissions that a caller has on the specified resource. If the * resource does not exist, this will return an empty set of permissions, not a * NOT_FOUND error. (groups.testIamPermissions) * * @param string $resource REQUIRED: The resource for which the policy detail is * being requested. See the operation documentation for the appropriate value * for this field. * @param TestIamPermissionsRequest $postBody * @param array $optParams Optional parameters. * @return TestIamPermissionsResponse */ public function testIamPermissions($resource, TestIamPermissionsRequest $postBody, $optParams = []) { $params = ['resource' => $resource, 'postBody' => $postBody]; $params = array_merge($params, $optParams); return $this->call('testIamPermissions', [$params], TestIamPermissionsResponse::class); } } // Adding a class alias for backwards compatibility with the previous class name. class_alias(ProjectsLocationsRegistriesGroups::class, 'Google_Service_CloudIot_Resource_ProjectsLocationsRegistriesGroups');