source: vendor/google/apiclient-services/src/ChecksService/Resource/ProjectsPrivacyPolicies.php

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

Upload project files

  • Property mode set to 100644
File size: 4.0 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\ChecksService\Resource;
19
20use Google\Service\ChecksService\ChecksEmpty;
21use Google\Service\ChecksService\FindPrivacyPolicyRequest;
22use Google\Service\ChecksService\ListPrivacyPoliciesResponse;
23use Google\Service\ChecksService\Operation;
24use Google\Service\ChecksService\PrivacyPolicy;
25
26/**
27 * The "privacyPolicies" collection of methods.
28 * Typical usage is:
29 * <code>
30 * $checksService = new Google\Service\ChecksService(...);
31 * $privacyPolicies = $checksService->projects_privacyPolicies;
32 * </code>
33 */
34class ProjectsPrivacyPolicies extends \Google\Service\Resource
35{
36 /**
37 * Deletes a privacy policy. (privacyPolicies.delete)
38 *
39 * @param string $name Required. Resource name of the privacy policy.
40 * @param array $optParams Optional parameters.
41 * @return ChecksEmpty
42 */
43 public function delete($name, $optParams = [])
44 {
45 $params = ['name' => $name];
46 $params = array_merge($params, $optParams);
47 return $this->call('delete', [$params], ChecksEmpty::class);
48 }
49 /**
50 * Finds the privacy policy of a given website. (privacyPolicies.find)
51 *
52 * @param string $parent Required. Resource name of the GCP project to which
53 * PrivacyPolicy resources will be added, in the format:
54 * `projects/{projectNumber}`.
55 * @param FindPrivacyPolicyRequest $postBody
56 * @param array $optParams Optional parameters.
57 * @return Operation
58 */
59 public function find($parent, FindPrivacyPolicyRequest $postBody, $optParams = [])
60 {
61 $params = ['parent' => $parent, 'postBody' => $postBody];
62 $params = array_merge($params, $optParams);
63 return $this->call('find', [$params], Operation::class);
64 }
65 /**
66 * Gets a privacy policy. (privacyPolicies.get)
67 *
68 * @param string $name Required. Resource name of the privacy policy.
69 * @param array $optParams Optional parameters.
70 * @return PrivacyPolicy
71 */
72 public function get($name, $optParams = [])
73 {
74 $params = ['name' => $name];
75 $params = array_merge($params, $optParams);
76 return $this->call('get', [$params], PrivacyPolicy::class);
77 }
78 /**
79 * Lists privacy policies. (privacyPolicies.listProjectsPrivacyPolicies)
80 *
81 * @param string $parent Required. Resource name of the parent project, in the
82 * format `projects/{projectNumber}`.
83 * @param array $optParams Optional parameters.
84 *
85 * @opt_param string filter Optional. A filter string to filters results. The
86 * filter syntax is defined by AIP-160 (https://google.aip.dev/160).
87 * @opt_param int pageSize Optional. The maximum number of results to return. If
88 * unspecified, at most 50 results will be returned. The maximum value is 1000;
89 * values above 1000 will be coerced to 1000.
90 * @opt_param string pageToken Optional. A page token, received from a previous
91 * `ListPrivacyPoliciesRequest` call. Provide this to retrieve the subsequent
92 * page. When paginating, all other parameters provided to
93 * `ListPrivacyPoliciesRequest` must match the call that provided the page
94 * token.
95 * @return ListPrivacyPoliciesResponse
96 */
97 public function listProjectsPrivacyPolicies($parent, $optParams = [])
98 {
99 $params = ['parent' => $parent];
100 $params = array_merge($params, $optParams);
101 return $this->call('list', [$params], ListPrivacyPoliciesResponse::class);
102 }
103}
104
105// Adding a class alias for backwards compatibility with the previous class name.
106class_alias(ProjectsPrivacyPolicies::class, 'Google_Service_ChecksService_Resource_ProjectsPrivacyPolicies');
Note: See TracBrowser for help on using the repository browser.