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\Baremetalsolution\Resource; 19 20use Google\Service\Baremetalsolution\ListNfsSharesResponse; 21use Google\Service\Baremetalsolution\NfsShare; 22use Google\Service\Baremetalsolution\Operation; 23 24/** 25 * The "nfsShares" collection of methods. 26 * Typical usage is: 27 * <code> 28 * $baremetalsolutionService = new Google\Service\Baremetalsolution(...); 29 * $nfsShares = $baremetalsolutionService->nfsShares; 30 * </code> 31 */ 32class ProjectsLocationsNfsShares extends \Google\Service\Resource 33{ 34 /** 35 * Get details of a single NFS share. (nfsShares.get) 36 * 37 * @param string $name Required. Name of the resource. 38 * @param array $optParams Optional parameters. 39 * @return NfsShare 40 */ 41 public function get($name, $optParams = []) 42 { 43 $params = ['name' => $name]; 44 $params = array_merge($params, $optParams); 45 return $this->call('get', [$params], NfsShare::class); 46 } 47 /** 48 * List NFS shares. (nfsShares.listProjectsLocationsNfsShares) 49 * 50 * @param string $parent Required. Parent value for ListNfsSharesRequest. 51 * @param array $optParams Optional parameters. 52 * 53 * @opt_param string filter List filter. 54 * @opt_param int pageSize Requested page size. The server might return fewer 55 * items than requested. If unspecified, server will pick an appropriate 56 * default. 57 * @opt_param string pageToken A token identifying a page of results from the 58 * server. 59 * @return ListNfsSharesResponse 60 */ 61 public function listProjectsLocationsNfsShares($parent, $optParams = []) 62 { 63 $params = ['parent' => $parent]; 64 $params = array_merge($params, $optParams); 65 return $this->call('list', [$params], ListNfsSharesResponse::class); 66 } 67 /** 68 * Update details of a single NFS share. (nfsShares.patch) 69 * 70 * @param string $name Output only. The name of the NFS share. 71 * @param NfsShare $postBody 72 * @param array $optParams Optional parameters. 73 * 74 * @opt_param string updateMask The list of fields to update. The only currently 75 * supported fields are: `labels` 76 * @return Operation 77 */ 78 public function patch($name, NfsShare $postBody, $optParams = []) 79 { 80 $params = ['name' => $name, 'postBody' => $postBody]; 81 $params = array_merge($params, $optParams); 82 return $this->call('patch', [$params], Operation::class); 83 } 84} 85 86// Adding a class alias for backwards compatibility with the previous class name. 87class_alias(ProjectsLocationsNfsShares::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsNfsShares'); 88