source: vendor/google/apiclient-services/src/AppHub/Resource/ProjectsLocations.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: 4.6 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\AppHub\Resource;
19
20use Google\Service\AppHub\DetachServiceProjectAttachmentRequest;
21use Google\Service\AppHub\DetachServiceProjectAttachmentResponse;
22use Google\Service\AppHub\ListLocationsResponse;
23use Google\Service\AppHub\Location;
24use Google\Service\AppHub\LookupServiceProjectAttachmentResponse;
25
26/**
27 * The "locations" collection of methods.
28 * Typical usage is:
29 * <code>
30 * $apphubService = new Google\Service\AppHub(...);
31 * $locations = $apphubService->projects_locations;
32 * </code>
33 */
34class ProjectsLocations extends \Google\Service\Resource
35{
36 /**
37 * Detaches a service project from a host project. You can call this API from
38 * any service project without needing access to the host project that it is
39 * attached to. (locations.detachServiceProjectAttachment)
40 *
41 * @param string $name Required. Service project id and location to detach from
42 * a host project. Only global location is supported. Expected format:
43 * `projects/{project}/locations/{location}`.
44 * @param DetachServiceProjectAttachmentRequest $postBody
45 * @param array $optParams Optional parameters.
46 * @return DetachServiceProjectAttachmentResponse
47 * @throws \Google\Service\Exception
48 */
49 public function detachServiceProjectAttachment($name, DetachServiceProjectAttachmentRequest $postBody, $optParams = [])
50 {
51 $params = ['name' => $name, 'postBody' => $postBody];
52 $params = array_merge($params, $optParams);
53 return $this->call('detachServiceProjectAttachment', [$params], DetachServiceProjectAttachmentResponse::class);
54 }
55 /**
56 * Gets information about a location. (locations.get)
57 *
58 * @param string $name Resource name for the location.
59 * @param array $optParams Optional parameters.
60 * @return Location
61 * @throws \Google\Service\Exception
62 */
63 public function get($name, $optParams = [])
64 {
65 $params = ['name' => $name];
66 $params = array_merge($params, $optParams);
67 return $this->call('get', [$params], Location::class);
68 }
69 /**
70 * Lists information about the supported locations for this service.
71 * (locations.listProjectsLocations)
72 *
73 * @param string $name The resource that owns the locations collection, if
74 * applicable.
75 * @param array $optParams Optional parameters.
76 *
77 * @opt_param string filter A filter to narrow down results to a preferred
78 * subset. The filtering language accepts strings like `"displayName=tokyo"`,
79 * and is documented in more detail in [AIP-160](https://google.aip.dev/160).
80 * @opt_param int pageSize The maximum number of results to return. If not set,
81 * the service selects a default.
82 * @opt_param string pageToken A page token received from the `next_page_token`
83 * field in the response. Send that page token to receive the subsequent page.
84 * @return ListLocationsResponse
85 * @throws \Google\Service\Exception
86 */
87 public function listProjectsLocations($name, $optParams = [])
88 {
89 $params = ['name' => $name];
90 $params = array_merge($params, $optParams);
91 return $this->call('list', [$params], ListLocationsResponse::class);
92 }
93 /**
94 * Lists a service project attachment for a given service project. You can call
95 * this API from any project to find if it is attached to a host project.
96 * (locations.lookupServiceProjectAttachment)
97 *
98 * @param string $name Required. Service project ID and location to lookup
99 * service project attachment for. Only global location is supported. Expected
100 * format: `projects/{project}/locations/{location}`.
101 * @param array $optParams Optional parameters.
102 * @return LookupServiceProjectAttachmentResponse
103 * @throws \Google\Service\Exception
104 */
105 public function lookupServiceProjectAttachment($name, $optParams = [])
106 {
107 $params = ['name' => $name];
108 $params = array_merge($params, $optParams);
109 return $this->call('lookupServiceProjectAttachment', [$params], LookupServiceProjectAttachmentResponse::class);
110 }
111}
112
113// Adding a class alias for backwards compatibility with the previous class name.
114class_alias(ProjectsLocations::class, 'Google_Service_AppHub_Resource_ProjectsLocations');
Note: See TracBrowser for help on using the repository browser.