source: vendor/google/apiclient-services/src/NetworkServices/Resource/ProjectsLocationsHttpRoutes.php

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

Upload project files

  • Property mode set to 100644
File size: 5.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\NetworkServices\Resource;
19
20use Google\Service\NetworkServices\HttpRoute;
21use Google\Service\NetworkServices\ListHttpRoutesResponse;
22use Google\Service\NetworkServices\Operation;
23
24/**
25 * The "httpRoutes" collection of methods.
26 * Typical usage is:
27 * <code>
28 * $networkservicesService = new Google\Service\NetworkServices(...);
29 * $httpRoutes = $networkservicesService->projects_locations_httpRoutes;
30 * </code>
31 */
32class ProjectsLocationsHttpRoutes extends \Google\Service\Resource
33{
34 /**
35 * Creates a new HttpRoute in a given project and location. (httpRoutes.create)
36 *
37 * @param string $parent Required. The parent resource of the HttpRoute. Must be
38 * in the format `projects/locations/global`.
39 * @param HttpRoute $postBody
40 * @param array $optParams Optional parameters.
41 *
42 * @opt_param string httpRouteId Required. Short name of the HttpRoute resource
43 * to be created.
44 * @return Operation
45 * @throws \Google\Service\Exception
46 */
47 public function create($parent, HttpRoute $postBody, $optParams = [])
48 {
49 $params = ['parent' => $parent, 'postBody' => $postBody];
50 $params = array_merge($params, $optParams);
51 return $this->call('create', [$params], Operation::class);
52 }
53 /**
54 * Deletes a single HttpRoute. (httpRoutes.delete)
55 *
56 * @param string $name Required. A name of the HttpRoute to delete. Must be in
57 * the format `projects/locations/global/httpRoutes`.
58 * @param array $optParams Optional parameters.
59 * @return Operation
60 * @throws \Google\Service\Exception
61 */
62 public function delete($name, $optParams = [])
63 {
64 $params = ['name' => $name];
65 $params = array_merge($params, $optParams);
66 return $this->call('delete', [$params], Operation::class);
67 }
68 /**
69 * Gets details of a single HttpRoute. (httpRoutes.get)
70 *
71 * @param string $name Required. A name of the HttpRoute to get. Must be in the
72 * format `projects/locations/global/httpRoutes`.
73 * @param array $optParams Optional parameters.
74 * @return HttpRoute
75 * @throws \Google\Service\Exception
76 */
77 public function get($name, $optParams = [])
78 {
79 $params = ['name' => $name];
80 $params = array_merge($params, $optParams);
81 return $this->call('get', [$params], HttpRoute::class);
82 }
83 /**
84 * Lists HttpRoute in a given project and location.
85 * (httpRoutes.listProjectsLocationsHttpRoutes)
86 *
87 * @param string $parent Required. The project and location from which the
88 * HttpRoutes should be listed, specified in the format
89 * `projects/locations/global`.
90 * @param array $optParams Optional parameters.
91 *
92 * @opt_param int pageSize Maximum number of HttpRoutes to return per call.
93 * @opt_param string pageToken The value returned by the last
94 * `ListHttpRoutesResponse` Indicates that this is a continuation of a prior
95 * `ListHttpRoutes` call, and that the system should return the next page of
96 * data.
97 * @return ListHttpRoutesResponse
98 * @throws \Google\Service\Exception
99 */
100 public function listProjectsLocationsHttpRoutes($parent, $optParams = [])
101 {
102 $params = ['parent' => $parent];
103 $params = array_merge($params, $optParams);
104 return $this->call('list', [$params], ListHttpRoutesResponse::class);
105 }
106 /**
107 * Updates the parameters of a single HttpRoute. (httpRoutes.patch)
108 *
109 * @param string $name Identifier. Name of the HttpRoute resource. It matches
110 * pattern `projects/locations/global/httpRoutes/http_route_name>`.
111 * @param HttpRoute $postBody
112 * @param array $optParams Optional parameters.
113 *
114 * @opt_param string updateMask Optional. Field mask is used to specify the
115 * fields to be overwritten in the HttpRoute resource by the update. The fields
116 * specified in the update_mask are relative to the resource, not the full
117 * request. A field will be overwritten if it is in the mask. If the user does
118 * not provide a mask then all fields will be overwritten.
119 * @return Operation
120 * @throws \Google\Service\Exception
121 */
122 public function patch($name, HttpRoute $postBody, $optParams = [])
123 {
124 $params = ['name' => $name, 'postBody' => $postBody];
125 $params = array_merge($params, $optParams);
126 return $this->call('patch', [$params], Operation::class);
127 }
128}
129
130// Adding a class alias for backwards compatibility with the previous class name.
131class_alias(ProjectsLocationsHttpRoutes::class, 'Google_Service_NetworkServices_Resource_ProjectsLocationsHttpRoutes');
Note: See TracBrowser for help on using the repository browser.