source: vendor/google/apiclient-services/src/Logging/Resource/ProjectsLocationsLogScopes.php

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

Upload project files

  • Property mode set to 100644
File size: 5.5 KB
RevLine 
[e3d4e0a]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\Logging\Resource;
19
20use Google\Service\Logging\ListLogScopesResponse;
21use Google\Service\Logging\LogScope;
22use Google\Service\Logging\LoggingEmpty;
23
24/**
25 * The "logScopes" collection of methods.
26 * Typical usage is:
27 * <code>
28 * $loggingService = new Google\Service\Logging(...);
29 * $logScopes = $loggingService->projects_locations_logScopes;
30 * </code>
31 */
32class ProjectsLocationsLogScopes extends \Google\Service\Resource
33{
34 /**
35 * Creates a log scope. (logScopes.create)
36 *
37 * @param string $parent Required. The parent project in which to create the log
38 * scope "projects/[PROJECT_ID]/locations/[LOCATION_ID]" For
39 * example:"projects/my-project/locations/global"
40 * @param LogScope $postBody
41 * @param array $optParams Optional parameters.
42 *
43 * @opt_param string logScopeId Required. A client-assigned identifier such as
44 * "log-scope". Identifiers are limited to 100 characters and can include only
45 * letters, digits, underscores, hyphens, and periods. First character has to be
46 * alphanumeric.
47 * @return LogScope
48 * @throws \Google\Service\Exception
49 */
50 public function create($parent, LogScope $postBody, $optParams = [])
51 {
52 $params = ['parent' => $parent, 'postBody' => $postBody];
53 $params = array_merge($params, $optParams);
54 return $this->call('create', [$params], LogScope::class);
55 }
56 /**
57 * Deletes a log scope. (logScopes.delete)
58 *
59 * @param string $name Required. The resource name of the log scope to delete:
60 * "projects/[PROJECT_ID]/locations/[LOCATION_ID]/logScopes/[LOG_SCOPE_ID]" For
61 * example:"projects/my-project/locations/global/logScopes/my-log-scope"
62 * @param array $optParams Optional parameters.
63 * @return LoggingEmpty
64 * @throws \Google\Service\Exception
65 */
66 public function delete($name, $optParams = [])
67 {
68 $params = ['name' => $name];
69 $params = array_merge($params, $optParams);
70 return $this->call('delete', [$params], LoggingEmpty::class);
71 }
72 /**
73 * Gets a log scope. (logScopes.get)
74 *
75 * @param string $name Required. The resource name of the log scope:
76 * "projects/[PROJECT_ID]/locations/[LOCATION_ID]/logScopes/[LOG_SCOPE_ID]" For
77 * example:"projects/my-project/locations/global/logScopes/my-log-scope"
78 * @param array $optParams Optional parameters.
79 * @return LogScope
80 * @throws \Google\Service\Exception
81 */
82 public function get($name, $optParams = [])
83 {
84 $params = ['name' => $name];
85 $params = array_merge($params, $optParams);
86 return $this->call('get', [$params], LogScope::class);
87 }
88 /**
89 * Lists log scopes. (logScopes.listProjectsLocationsLogScopes)
90 *
91 * @param string $parent Required. The parent resource whose log scopes are to
92 * be listed: "projects/[PROJECT_ID]/locations/[LOCATION_ID]"
93 * @param array $optParams Optional parameters.
94 *
95 * @opt_param int pageSize Optional. The maximum number of results to return
96 * from this request.Non-positive values are ignored. The presence of
97 * nextPageToken in the response indicates that more results might be available.
98 * @opt_param string pageToken Optional. If present, then retrieve the next
99 * batch of results from the preceding call to this method. pageToken must be
100 * the value of nextPageToken from the previous response. The values of other
101 * method parameters should be identical to those in the previous call.
102 * @return ListLogScopesResponse
103 * @throws \Google\Service\Exception
104 */
105 public function listProjectsLocationsLogScopes($parent, $optParams = [])
106 {
107 $params = ['parent' => $parent];
108 $params = array_merge($params, $optParams);
109 return $this->call('list', [$params], ListLogScopesResponse::class);
110 }
111 /**
112 * Updates a log scope. (logScopes.patch)
113 *
114 * @param string $name Output only. The resource name of the log scope.Log
115 * scopes are only available in the global location. For example:projects/my-
116 * project/locations/global/logScopes/my-log-scope
117 * @param LogScope $postBody
118 * @param array $optParams Optional parameters.
119 *
120 * @opt_param string updateMask Optional. Field mask that specifies the fields
121 * in log_scope that need an update. A field will be overwritten if, and only
122 * if, it is in the update mask. name and output only fields cannot be
123 * updated.For a detailed FieldMask definition, see
124 * https://developers.google.com/protocol-
125 * buffers/docs/reference/google.protobuf#google.protobuf.FieldMaskFor example:
126 * updateMask=description
127 * @return LogScope
128 * @throws \Google\Service\Exception
129 */
130 public function patch($name, LogScope $postBody, $optParams = [])
131 {
132 $params = ['name' => $name, 'postBody' => $postBody];
133 $params = array_merge($params, $optParams);
134 return $this->call('patch', [$params], LogScope::class);
135 }
136}
137
138// Adding a class alias for backwards compatibility with the previous class name.
139class_alias(ProjectsLocationsLogScopes::class, 'Google_Service_Logging_Resource_ProjectsLocationsLogScopes');
Note: See TracBrowser for help on using the repository browser.