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\Contactcenterinsights\Resource;
|
---|
19 |
|
---|
20 | use Google\Service\Contactcenterinsights\GoogleCloudContactcenterinsightsV1ListPhraseMatchersResponse;
|
---|
21 | use Google\Service\Contactcenterinsights\GoogleCloudContactcenterinsightsV1PhraseMatcher;
|
---|
22 | use Google\Service\Contactcenterinsights\GoogleProtobufEmpty;
|
---|
23 |
|
---|
24 | /**
|
---|
25 | * The "phraseMatchers" collection of methods.
|
---|
26 | * Typical usage is:
|
---|
27 | * <code>
|
---|
28 | * $contactcenterinsightsService = new Google\Service\Contactcenterinsights(...);
|
---|
29 | * $phraseMatchers = $contactcenterinsightsService->projects_locations_phraseMatchers;
|
---|
30 | * </code>
|
---|
31 | */
|
---|
32 | class ProjectsLocationsPhraseMatchers extends \Google\Service\Resource
|
---|
33 | {
|
---|
34 | /**
|
---|
35 | * Creates a phrase matcher. (phraseMatchers.create)
|
---|
36 | *
|
---|
37 | * @param string $parent Required. The parent resource of the phrase matcher.
|
---|
38 | * Required. The location to create a phrase matcher for. Format:
|
---|
39 | * `projects//locations/` or `projects//locations/`
|
---|
40 | * @param GoogleCloudContactcenterinsightsV1PhraseMatcher $postBody
|
---|
41 | * @param array $optParams Optional parameters.
|
---|
42 | * @return GoogleCloudContactcenterinsightsV1PhraseMatcher
|
---|
43 | * @throws \Google\Service\Exception
|
---|
44 | */
|
---|
45 | public function create($parent, GoogleCloudContactcenterinsightsV1PhraseMatcher $postBody, $optParams = [])
|
---|
46 | {
|
---|
47 | $params = ['parent' => $parent, 'postBody' => $postBody];
|
---|
48 | $params = array_merge($params, $optParams);
|
---|
49 | return $this->call('create', [$params], GoogleCloudContactcenterinsightsV1PhraseMatcher::class);
|
---|
50 | }
|
---|
51 | /**
|
---|
52 | * Deletes a phrase matcher. (phraseMatchers.delete)
|
---|
53 | *
|
---|
54 | * @param string $name Required. The name of the phrase matcher to delete.
|
---|
55 | * @param array $optParams Optional parameters.
|
---|
56 | * @return GoogleProtobufEmpty
|
---|
57 | * @throws \Google\Service\Exception
|
---|
58 | */
|
---|
59 | public function delete($name, $optParams = [])
|
---|
60 | {
|
---|
61 | $params = ['name' => $name];
|
---|
62 | $params = array_merge($params, $optParams);
|
---|
63 | return $this->call('delete', [$params], GoogleProtobufEmpty::class);
|
---|
64 | }
|
---|
65 | /**
|
---|
66 | * Gets a phrase matcher. (phraseMatchers.get)
|
---|
67 | *
|
---|
68 | * @param string $name Required. The name of the phrase matcher to get.
|
---|
69 | * @param array $optParams Optional parameters.
|
---|
70 | * @return GoogleCloudContactcenterinsightsV1PhraseMatcher
|
---|
71 | * @throws \Google\Service\Exception
|
---|
72 | */
|
---|
73 | public function get($name, $optParams = [])
|
---|
74 | {
|
---|
75 | $params = ['name' => $name];
|
---|
76 | $params = array_merge($params, $optParams);
|
---|
77 | return $this->call('get', [$params], GoogleCloudContactcenterinsightsV1PhraseMatcher::class);
|
---|
78 | }
|
---|
79 | /**
|
---|
80 | * Lists phrase matchers. (phraseMatchers.listProjectsLocationsPhraseMatchers)
|
---|
81 | *
|
---|
82 | * @param string $parent Required. The parent resource of the phrase matcher.
|
---|
83 | * @param array $optParams Optional parameters.
|
---|
84 | *
|
---|
85 | * @opt_param string filter A filter to reduce results to a specific subset.
|
---|
86 | * Useful for querying phrase matchers with specific properties.
|
---|
87 | * @opt_param int pageSize The maximum number of phrase matchers to return in
|
---|
88 | * the response. If this value is zero, the service will select a default size.
|
---|
89 | * A call might return fewer objects than requested. A non-empty
|
---|
90 | * `next_page_token` in the response indicates that more data is available.
|
---|
91 | * @opt_param string pageToken The value returned by the last
|
---|
92 | * `ListPhraseMatchersResponse`. This value indicates that this is a
|
---|
93 | * continuation of a prior `ListPhraseMatchers` call and that the system should
|
---|
94 | * return the next page of data.
|
---|
95 | * @return GoogleCloudContactcenterinsightsV1ListPhraseMatchersResponse
|
---|
96 | * @throws \Google\Service\Exception
|
---|
97 | */
|
---|
98 | public function listProjectsLocationsPhraseMatchers($parent, $optParams = [])
|
---|
99 | {
|
---|
100 | $params = ['parent' => $parent];
|
---|
101 | $params = array_merge($params, $optParams);
|
---|
102 | return $this->call('list', [$params], GoogleCloudContactcenterinsightsV1ListPhraseMatchersResponse::class);
|
---|
103 | }
|
---|
104 | /**
|
---|
105 | * Updates a phrase matcher. (phraseMatchers.patch)
|
---|
106 | *
|
---|
107 | * @param string $name The resource name of the phrase matcher. Format:
|
---|
108 | * projects/{project}/locations/{location}/phraseMatchers/{phrase_matcher}
|
---|
109 | * @param GoogleCloudContactcenterinsightsV1PhraseMatcher $postBody
|
---|
110 | * @param array $optParams Optional parameters.
|
---|
111 | *
|
---|
112 | * @opt_param string updateMask The list of fields to be updated.
|
---|
113 | * @return GoogleCloudContactcenterinsightsV1PhraseMatcher
|
---|
114 | * @throws \Google\Service\Exception
|
---|
115 | */
|
---|
116 | public function patch($name, GoogleCloudContactcenterinsightsV1PhraseMatcher $postBody, $optParams = [])
|
---|
117 | {
|
---|
118 | $params = ['name' => $name, 'postBody' => $postBody];
|
---|
119 | $params = array_merge($params, $optParams);
|
---|
120 | return $this->call('patch', [$params], GoogleCloudContactcenterinsightsV1PhraseMatcher::class);
|
---|
121 | }
|
---|
122 | }
|
---|
123 |
|
---|
124 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
125 | class_alias(ProjectsLocationsPhraseMatchers::class, 'Google_Service_Contactcenterinsights_Resource_ProjectsLocationsPhraseMatchers');
|
---|