Initial commit

This commit is contained in:
Local Administrator
2025-04-18 10:32:42 +02:00
commit b83134aca3
29643 changed files with 3045897 additions and 0 deletions

View File

@@ -0,0 +1,116 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\BaremetalsolutionEmpty;
use Google\Service\Baremetalsolution\CancelOperationRequest;
use Google\Service\Baremetalsolution\ListOperationsResponse;
use Google\Service\Baremetalsolution\Operation;
/**
* The "operations" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $operations = $baremetalsolutionService->operations;
* </code>
*/
class Operations extends \Google\Service\Resource
{
/**
* Starts asynchronous cancellation on a long-running operation. The server
* makes a best effort to cancel the operation, but success is not guaranteed.
* If the server doesn't support this method, it returns
* `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or
* other methods to check whether the cancellation succeeded or whether the
* operation completed despite cancellation. On successful cancellation, the
* operation is not deleted; instead, it becomes an operation with an
* Operation.error value with a google.rpc.Status.code of 1, corresponding to
* `Code.CANCELLED`. (operations.cancel)
*
* @param string $name The name of the operation resource to be cancelled.
* @param CancelOperationRequest $postBody
* @param array $optParams Optional parameters.
* @return BaremetalsolutionEmpty
*/
public function cancel($name, CancelOperationRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('cancel', [$params], BaremetalsolutionEmpty::class);
}
/**
* Deletes a long-running operation. This method indicates that the client is no
* longer interested in the operation result. It does not cancel the operation.
* If the server doesn't support this method, it returns
* `google.rpc.Code.UNIMPLEMENTED`. (operations.delete)
*
* @param string $name The name of the operation resource to be deleted.
* @param array $optParams Optional parameters.
* @return BaremetalsolutionEmpty
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], BaremetalsolutionEmpty::class);
}
/**
* Gets the latest state of a long-running operation. Clients can use this
* method to poll the operation result at intervals as recommended by the API
* service. (operations.get)
*
* @param string $name The name of the operation resource.
* @param array $optParams Optional parameters.
* @return Operation
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Operation::class);
}
/**
* Lists operations that match the specified filter in the request. If the
* server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the
* `name` binding allows API services to override the binding to use different
* resource name schemes, such as `users/operations`. To override the binding,
* API services can add a binding such as `"/v1/{name=users}/operations"` to
* their service configuration. For backwards compatibility, the default name
* includes the operations collection id, however overriding users must ensure
* the name binding is the parent resource, without the operations collection
* id. (operations.listOperations)
*
* @param string $name The name of the operation's parent resource.
* @param array $optParams Optional parameters.
*
* @opt_param string filter The standard list filter.
* @opt_param int pageSize The standard list page size.
* @opt_param string pageToken The standard list page token.
* @return ListOperationsResponse
*/
public function listOperations($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListOperationsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Operations::class, 'Google_Service_Baremetalsolution_Resource_Operations');

View File

@@ -0,0 +1,33 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
/**
* The "projects" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $projects = $baremetalsolutionService->projects;
* </code>
*/
class Projects extends \Google\Service\Resource
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Projects::class, 'Google_Service_Baremetalsolution_Resource_Projects');

View File

@@ -0,0 +1,74 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\ListLocationsResponse;
use Google\Service\Baremetalsolution\Location;
/**
* The "locations" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $locations = $baremetalsolutionService->projects_locations;
* </code>
*/
class ProjectsLocations extends \Google\Service\Resource
{
/**
* Gets information about a location. (locations.get)
*
* @param string $name Resource name for the location.
* @param array $optParams Optional parameters.
* @return Location
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Location::class);
}
/**
* Lists information about the supported locations for this service.
* (locations.listProjectsLocations)
*
* @param string $name The resource that owns the locations collection, if
* applicable.
* @param array $optParams Optional parameters.
*
* @opt_param string filter A filter to narrow down results to a preferred
* subset. The filtering language accepts strings like `"displayName=tokyo"`,
* and is documented in more detail in [AIP-160](https://google.aip.dev/160).
* @opt_param int pageSize The maximum number of results to return. If not set,
* the service selects a default.
* @opt_param string pageToken A page token received from the `next_page_token`
* field in the response. Send that page token to receive the subsequent page.
* @return ListLocationsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocations($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListLocationsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocations::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocations');

View File

@@ -0,0 +1,50 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\FetchInstanceProvisioningSettingsResponse;
/**
* The "instanceProvisioningSettings" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $instanceProvisioningSettings = $baremetalsolutionService->projects_locations_instanceProvisioningSettings;
* </code>
*/
class ProjectsLocationsInstanceProvisioningSettings extends \Google\Service\Resource
{
/**
* Get instance provisioning settings for a given project. This is hidden method
* used by UI only. (instanceProvisioningSettings.fetch)
*
* @param string $location Required. The parent project and location containing
* the ProvisioningSettings.
* @param array $optParams Optional parameters.
* @return FetchInstanceProvisioningSettingsResponse
*/
public function fetch($location, $optParams = [])
{
$params = ['location' => $location];
$params = array_merge($params, $optParams);
return $this->call('fetch', [$params], FetchInstanceProvisioningSettingsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsInstanceProvisioningSettings::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsInstanceProvisioningSettings');

View File

@@ -0,0 +1,283 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\DetachLunRequest;
use Google\Service\Baremetalsolution\DisableHyperthreadingRequest;
use Google\Service\Baremetalsolution\DisableInteractiveSerialConsoleRequest;
use Google\Service\Baremetalsolution\EnableHyperthreadingRequest;
use Google\Service\Baremetalsolution\EnableInteractiveSerialConsoleRequest;
use Google\Service\Baremetalsolution\Instance;
use Google\Service\Baremetalsolution\ListInstancesResponse;
use Google\Service\Baremetalsolution\LoadInstanceAuthInfoResponse;
use Google\Service\Baremetalsolution\Operation;
use Google\Service\Baremetalsolution\ReimageInstanceRequest;
use Google\Service\Baremetalsolution\RenameInstanceRequest;
use Google\Service\Baremetalsolution\ResetInstanceRequest;
use Google\Service\Baremetalsolution\StartInstanceRequest;
use Google\Service\Baremetalsolution\StopInstanceRequest;
/**
* The "instances" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $instances = $baremetalsolutionService->projects_locations_instances;
* </code>
*/
class ProjectsLocationsInstances extends \Google\Service\Resource
{
/**
* Detach LUN from Instance. (instances.detachLun)
*
* @param string $instance Required. Name of the instance.
* @param DetachLunRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function detachLun($instance, DetachLunRequest $postBody, $optParams = [])
{
$params = ['instance' => $instance, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('detachLun', [$params], Operation::class);
}
/**
* Perform disable hyperthreading operation on a single server.
* (instances.disableHyperthreading)
*
* @param string $name Required. The `name` field is used to identify the
* instance. Format:
* projects/{project}/locations/{location}/instances/{instance}
* @param DisableHyperthreadingRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function disableHyperthreading($name, DisableHyperthreadingRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('disableHyperthreading', [$params], Operation::class);
}
/**
* Disable the interactive serial console feature on an instance.
* (instances.disableInteractiveSerialConsole)
*
* @param string $name Required. Name of the resource.
* @param DisableInteractiveSerialConsoleRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function disableInteractiveSerialConsole($name, DisableInteractiveSerialConsoleRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('disableInteractiveSerialConsole', [$params], Operation::class);
}
/**
* Perform enable hyperthreading operation on a single server.
* (instances.enableHyperthreading)
*
* @param string $name Required. The `name` field is used to identify the
* instance. Format:
* projects/{project}/locations/{location}/instances/{instance}
* @param EnableHyperthreadingRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function enableHyperthreading($name, EnableHyperthreadingRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('enableHyperthreading', [$params], Operation::class);
}
/**
* Enable the interactive serial console feature on an instance.
* (instances.enableInteractiveSerialConsole)
*
* @param string $name Required. Name of the resource.
* @param EnableInteractiveSerialConsoleRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function enableInteractiveSerialConsole($name, EnableInteractiveSerialConsoleRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('enableInteractiveSerialConsole', [$params], Operation::class);
}
/**
* Get details about a single server. (instances.get)
*
* @param string $name Required. Name of the resource.
* @param array $optParams Optional parameters.
* @return Instance
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Instance::class);
}
/**
* List servers in a given project and location.
* (instances.listProjectsLocationsInstances)
*
* @param string $parent Required. Parent value for ListInstancesRequest.
* @param array $optParams Optional parameters.
*
* @opt_param string filter List filter.
* @opt_param int pageSize Requested page size. Server may return fewer items
* than requested. If unspecified, the server will pick an appropriate default.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListInstancesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsInstances($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListInstancesResponse::class);
}
/**
* Load auth info for a server. (instances.loadAuthInfo)
*
* @param string $name Required. Name of the server.
* @param array $optParams Optional parameters.
* @return LoadInstanceAuthInfoResponse
* @throws \Google\Service\Exception
*/
public function loadAuthInfo($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('loadAuthInfo', [$params], LoadInstanceAuthInfoResponse::class);
}
/**
* Update details of a single server. (instances.patch)
*
* @param string $name Immutable. The resource name of this `Instance`. Resource
* names are schemeless URIs that follow the conventions in
* https://cloud.google.com/apis/design/resource_names. Format:
* `projects/{project}/locations/{location}/instances/{instance}`
* @param Instance $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask The list of fields to update. The currently
* supported fields are: `labels` `hyperthreading_enabled` `os_image` `ssh_keys`
* `kms_key_version`
* @return Operation
* @throws \Google\Service\Exception
*/
public function patch($name, Instance $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Operation::class);
}
/**
* Perform reimage operation on a single server. (instances.reimage)
*
* @param string $name Required. The `name` field is used to identify the
* instance. Format:
* projects/{project}/locations/{location}/instances/{instance}
* @param ReimageInstanceRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function reimage($name, ReimageInstanceRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('reimage', [$params], Operation::class);
}
/**
* RenameInstance sets a new name for an instance. Use with caution, previous
* names become immediately invalidated. (instances.rename)
*
* @param string $name Required. The `name` field is used to identify the
* instance. Format:
* projects/{project}/locations/{location}/instances/{instance}
* @param RenameInstanceRequest $postBody
* @param array $optParams Optional parameters.
* @return Instance
* @throws \Google\Service\Exception
*/
public function rename($name, RenameInstanceRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('rename', [$params], Instance::class);
}
/**
* Perform an ungraceful, hard reset on a server. Equivalent to shutting the
* power off and then turning it back on. (instances.reset)
*
* @param string $name Required. Name of the resource.
* @param ResetInstanceRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function reset($name, ResetInstanceRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('reset', [$params], Operation::class);
}
/**
* Starts a server that was shutdown. (instances.start)
*
* @param string $name Required. Name of the resource.
* @param StartInstanceRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function start($name, StartInstanceRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('start', [$params], Operation::class);
}
/**
* Stop a running server. (instances.stop)
*
* @param string $name Required. Name of the resource.
* @param StopInstanceRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function stop($name, StopInstanceRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('stop', [$params], Operation::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsInstances::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsInstances');

View File

@@ -0,0 +1,128 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\ListNetworkUsageResponse;
use Google\Service\Baremetalsolution\ListNetworksResponse;
use Google\Service\Baremetalsolution\Network;
use Google\Service\Baremetalsolution\Operation;
use Google\Service\Baremetalsolution\RenameNetworkRequest;
/**
* The "networks" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $networks = $baremetalsolutionService->projects_locations_networks;
* </code>
*/
class ProjectsLocationsNetworks extends \Google\Service\Resource
{
/**
* Get details of a single network. (networks.get)
*
* @param string $name Required. Name of the resource.
* @param array $optParams Optional parameters.
* @return Network
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Network::class);
}
/**
* List network in a given project and location.
* (networks.listProjectsLocationsNetworks)
*
* @param string $parent Required. Parent value for ListNetworksRequest.
* @param array $optParams Optional parameters.
*
* @opt_param string filter List filter.
* @opt_param int pageSize Requested page size. The server might return fewer
* items than requested. If unspecified, server will pick an appropriate
* default.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListNetworksResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsNetworks($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListNetworksResponse::class);
}
/**
* List all Networks (and used IPs for each Network) in the vendor account
* associated with the specified project. (networks.listNetworkUsage)
*
* @param string $location Required. Parent value (project and location).
* @param array $optParams Optional parameters.
* @return ListNetworkUsageResponse
* @throws \Google\Service\Exception
*/
public function listNetworkUsage($location, $optParams = [])
{
$params = ['location' => $location];
$params = array_merge($params, $optParams);
return $this->call('listNetworkUsage', [$params], ListNetworkUsageResponse::class);
}
/**
* Update details of a single network. (networks.patch)
*
* @param string $name Output only. The resource name of this `Network`.
* Resource names are schemeless URIs that follow the conventions in
* https://cloud.google.com/apis/design/resource_names. Format:
* `projects/{project}/locations/{location}/networks/{network}`
* @param Network $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask The list of fields to update. The only currently
* supported fields are: `labels`, `reservations`, `vrf.vlan_attachments`
* @return Operation
* @throws \Google\Service\Exception
*/
public function patch($name, Network $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Operation::class);
}
/**
* RenameNetwork sets a new name for a network. Use with caution, previous names
* become immediately invalidated. (networks.rename)
*
* @param string $name Required. The `name` field is used to identify the
* network. Format: projects/{project}/locations/{location}/networks/{network}
* @param RenameNetworkRequest $postBody
* @param array $optParams Optional parameters.
* @return Network
* @throws \Google\Service\Exception
*/
public function rename($name, RenameNetworkRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('rename', [$params], Network::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsNetworks::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsNetworks');

View File

@@ -0,0 +1,139 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\ListNfsSharesResponse;
use Google\Service\Baremetalsolution\NfsShare;
use Google\Service\Baremetalsolution\Operation;
use Google\Service\Baremetalsolution\RenameNfsShareRequest;
/**
* The "nfsShares" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $nfsShares = $baremetalsolutionService->projects_locations_nfsShares;
* </code>
*/
class ProjectsLocationsNfsShares extends \Google\Service\Resource
{
/**
* Create an NFS share. (nfsShares.create)
*
* @param string $parent Required. The parent project and location.
* @param NfsShare $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function create($parent, NfsShare $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Operation::class);
}
/**
* Delete an NFS share. The underlying volume is automatically deleted.
* (nfsShares.delete)
*
* @param string $name Required. The name of the NFS share to delete.
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], Operation::class);
}
/**
* Get details of a single NFS share. (nfsShares.get)
*
* @param string $name Required. Name of the resource.
* @param array $optParams Optional parameters.
* @return NfsShare
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], NfsShare::class);
}
/**
* List NFS shares. (nfsShares.listProjectsLocationsNfsShares)
*
* @param string $parent Required. Parent value for ListNfsSharesRequest.
* @param array $optParams Optional parameters.
*
* @opt_param string filter List filter.
* @opt_param int pageSize Requested page size. The server might return fewer
* items than requested. If unspecified, server will pick an appropriate
* default.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListNfsSharesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsNfsShares($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListNfsSharesResponse::class);
}
/**
* Update details of a single NFS share. (nfsShares.patch)
*
* @param string $name Immutable. The name of the NFS share.
* @param NfsShare $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask The list of fields to update. The only currently
* supported fields are: `labels` `allowed_clients`
* @return Operation
* @throws \Google\Service\Exception
*/
public function patch($name, NfsShare $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Operation::class);
}
/**
* RenameNfsShare sets a new name for an nfsshare. Use with caution, previous
* names become immediately invalidated. (nfsShares.rename)
*
* @param string $name Required. The `name` field is used to identify the
* nfsshare. Format:
* projects/{project}/locations/{location}/nfsshares/{nfsshare}
* @param RenameNfsShareRequest $postBody
* @param array $optParams Optional parameters.
* @return NfsShare
* @throws \Google\Service\Exception
*/
public function rename($name, RenameNfsShareRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('rename', [$params], NfsShare::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsNfsShares::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsNfsShares');

View File

@@ -0,0 +1,49 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\Operation;
/**
* The "operations" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $operations = $baremetalsolutionService->projects_locations_operations;
* </code>
*/
class ProjectsLocationsOperations extends \Google\Service\Resource
{
/**
* Get details about an operation. (operations.get)
*
* @param string $name The name of the operation resource.
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Operation::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsOperations::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsOperations');

View File

@@ -0,0 +1,72 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\ListOSImagesResponse;
use Google\Service\Baremetalsolution\OSImage;
/**
* The "osImages" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $osImages = $baremetalsolutionService->projects_locations_osImages;
* </code>
*/
class ProjectsLocationsOsImages extends \Google\Service\Resource
{
/**
* Get details of a single OS image. (osImages.get)
*
* @param string $name Required. Name of the OS image.
* @param array $optParams Optional parameters.
* @return OSImage
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], OSImage::class);
}
/**
* Retrieves the list of OS images which are currently approved.
* (osImages.listProjectsLocationsOsImages)
*
* @param string $parent Required. Parent value for ListOSImagesRequest.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize Requested page size. The server might return fewer
* items than requested. If unspecified, server will pick an appropriate
* default. Notice that page_size field is not supported and won't be respected
* in the API request for now, will be updated when pagination is supported.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListOSImagesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsOsImages($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListOSImagesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsOsImages::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsOsImages');

View File

@@ -0,0 +1,107 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\ProvisioningConfig;
use Google\Service\Baremetalsolution\SubmitProvisioningConfigRequest;
use Google\Service\Baremetalsolution\SubmitProvisioningConfigResponse;
/**
* The "provisioningConfigs" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $provisioningConfigs = $baremetalsolutionService->projects_locations_provisioningConfigs;
* </code>
*/
class ProjectsLocationsProvisioningConfigs extends \Google\Service\Resource
{
/**
* Create new ProvisioningConfig. (provisioningConfigs.create)
*
* @param string $parent Required. The parent project and location containing
* the ProvisioningConfig.
* @param ProvisioningConfig $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string email Optional. Email provided to send a confirmation with
* provisioning config to.
* @return ProvisioningConfig
* @throws \Google\Service\Exception
*/
public function create($parent, ProvisioningConfig $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], ProvisioningConfig::class);
}
/**
* Get ProvisioningConfig by name. (provisioningConfigs.get)
*
* @param string $name Required. Name of the ProvisioningConfig.
* @param array $optParams Optional parameters.
* @return ProvisioningConfig
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], ProvisioningConfig::class);
}
/**
* Update existing ProvisioningConfig. (provisioningConfigs.patch)
*
* @param string $name Output only. The system-generated name of the
* provisioning config. This follows the UUID format.
* @param ProvisioningConfig $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string email Optional. Email provided to send a confirmation with
* provisioning config to.
* @opt_param string updateMask Required. The list of fields to update.
* @return ProvisioningConfig
* @throws \Google\Service\Exception
*/
public function patch($name, ProvisioningConfig $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], ProvisioningConfig::class);
}
/**
* Submit a provisiong configuration for a given project.
* (provisioningConfigs.submit)
*
* @param string $parent Required. The parent project and location containing
* the ProvisioningConfig.
* @param SubmitProvisioningConfigRequest $postBody
* @param array $optParams Optional parameters.
* @return SubmitProvisioningConfigResponse
* @throws \Google\Service\Exception
*/
public function submit($parent, SubmitProvisioningConfigRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('submit', [$params], SubmitProvisioningConfigResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsProvisioningConfigs::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsProvisioningConfigs');

View File

@@ -0,0 +1,58 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\ListProvisioningQuotasResponse;
/**
* The "provisioningQuotas" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $provisioningQuotas = $baremetalsolutionService->projects_locations_provisioningQuotas;
* </code>
*/
class ProjectsLocationsProvisioningQuotas extends \Google\Service\Resource
{
/**
* List the budget details to provision resources on a given project.
* (provisioningQuotas.listProjectsLocationsProvisioningQuotas)
*
* @param string $parent Required. Parent value for
* ListProvisioningQuotasRequest.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize Requested page size. The server might return fewer
* items than requested. If unspecified, server will pick an appropriate
* default. Notice that page_size field is not supported and won't be respected
* in the API request for now, will be updated when pagination is supported.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListProvisioningQuotasResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsProvisioningQuotas($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListProvisioningQuotasResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsProvisioningQuotas::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsProvisioningQuotas');

View File

@@ -0,0 +1,120 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\BaremetalsolutionEmpty;
use Google\Service\Baremetalsolution\ListSnapshotSchedulePoliciesResponse;
use Google\Service\Baremetalsolution\SnapshotSchedulePolicy;
/**
* The "snapshotSchedulePolicies" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $snapshotSchedulePolicies = $baremetalsolutionService->snapshotSchedulePolicies;
* </code>
*/
class ProjectsLocationsSnapshotSchedulePolicies extends \Google\Service\Resource
{
/**
* Create a snapshot schedule policy in the specified project.
* (snapshotSchedulePolicies.create)
*
* @param string $parent Required. The parent project and location containing
* the SnapshotSchedulePolicy.
* @param SnapshotSchedulePolicy $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string snapshotSchedulePolicyId Required. Snapshot policy ID
* @return SnapshotSchedulePolicy
*/
public function create($parent, SnapshotSchedulePolicy $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], SnapshotSchedulePolicy::class);
}
/**
* Delete a named snapshot schedule policy. (snapshotSchedulePolicies.delete)
*
* @param string $name Required. The name of the snapshot schedule policy to
* delete.
* @param array $optParams Optional parameters.
* @return BaremetalsolutionEmpty
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], BaremetalsolutionEmpty::class);
}
/**
* Get details of a single snapshot schedule policy.
* (snapshotSchedulePolicies.get)
*
* @param string $name Required. Name of the resource.
* @param array $optParams Optional parameters.
* @return SnapshotSchedulePolicy
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], SnapshotSchedulePolicy::class);
}
/**
* List snapshot schedule policies in a given project and location.
* (snapshotSchedulePolicies.listProjectsLocationsSnapshotSchedulePolicies)
*
* @param string $parent Required. The parent project containing the Snapshot
* Schedule Policies.
* @param array $optParams Optional parameters.
*
* @opt_param string filter List filter.
* @opt_param int pageSize The maximum number of items to return.
* @opt_param string pageToken The next_page_token value returned from a
* previous List request, if any.
* @return ListSnapshotSchedulePoliciesResponse
*/
public function listProjectsLocationsSnapshotSchedulePolicies($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListSnapshotSchedulePoliciesResponse::class);
}
/**
* Update a snapshot schedule policy in the specified project.
* (snapshotSchedulePolicies.patch)
*
* @param string $name Output only. The name of the snapshot schedule policy.
* @param SnapshotSchedulePolicy $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask Required. The list of fields to update.
* @return SnapshotSchedulePolicy
*/
public function patch($name, SnapshotSchedulePolicy $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], SnapshotSchedulePolicy::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsSnapshotSchedulePolicies::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsSnapshotSchedulePolicies');

View File

@@ -0,0 +1,94 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\BaremetalsolutionEmpty;
use Google\Service\Baremetalsolution\ListSSHKeysResponse;
use Google\Service\Baremetalsolution\SSHKey;
/**
* The "sshKeys" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $sshKeys = $baremetalsolutionService->projects_locations_sshKeys;
* </code>
*/
class ProjectsLocationsSshKeys extends \Google\Service\Resource
{
/**
* Register a public SSH key in the specified project for use with the
* interactive serial console feature. (sshKeys.create)
*
* @param string $parent Required. The parent containing the SSH keys.
* @param SSHKey $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string sshKeyId Required. The ID to use for the key, which will
* become the final component of the key's resource name. This value must match
* the regex: [a-zA-Z0-9@.\-_]{1,64}
* @return SSHKey
* @throws \Google\Service\Exception
*/
public function create($parent, SSHKey $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], SSHKey::class);
}
/**
* Deletes a public SSH key registered in the specified project.
* (sshKeys.delete)
*
* @param string $name Required. The name of the SSH key to delete. Currently,
* the only valid value for the location is "global".
* @param array $optParams Optional parameters.
* @return BaremetalsolutionEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], BaremetalsolutionEmpty::class);
}
/**
* Lists the public SSH keys registered for the specified project. These SSH
* keys are used only for the interactive serial console feature.
* (sshKeys.listProjectsLocationsSshKeys)
*
* @param string $parent Required. The parent containing the SSH keys.
* Currently, the only valid value for the location is "global".
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize The maximum number of items to return.
* @opt_param string pageToken The next_page_token value returned from a
* previous List request, if any.
* @return ListSSHKeysResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsSshKeys($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListSSHKeysResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsSshKeys::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsSshKeys');

View File

@@ -0,0 +1,145 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\EvictVolumeRequest;
use Google\Service\Baremetalsolution\ListVolumesResponse;
use Google\Service\Baremetalsolution\Operation;
use Google\Service\Baremetalsolution\RenameVolumeRequest;
use Google\Service\Baremetalsolution\ResizeVolumeRequest;
use Google\Service\Baremetalsolution\Volume;
/**
* The "volumes" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $volumes = $baremetalsolutionService->projects_locations_volumes;
* </code>
*/
class ProjectsLocationsVolumes extends \Google\Service\Resource
{
/**
* Skips volume's cooloff and deletes it now. Volume must be in cooloff state.
* (volumes.evict)
*
* @param string $name Required. The name of the Volume.
* @param EvictVolumeRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function evict($name, EvictVolumeRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('evict', [$params], Operation::class);
}
/**
* Get details of a single storage volume. (volumes.get)
*
* @param string $name Required. Name of the resource.
* @param array $optParams Optional parameters.
* @return Volume
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Volume::class);
}
/**
* List storage volumes in a given project and location.
* (volumes.listProjectsLocationsVolumes)
*
* @param string $parent Required. Parent value for ListVolumesRequest.
* @param array $optParams Optional parameters.
*
* @opt_param string filter List filter.
* @opt_param int pageSize Requested page size. The server might return fewer
* items than requested. If unspecified, server will pick an appropriate
* default.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListVolumesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsVolumes($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListVolumesResponse::class);
}
/**
* Update details of a single storage volume. (volumes.patch)
*
* @param string $name Output only. The resource name of this `Volume`. Resource
* names are schemeless URIs that follow the conventions in
* https://cloud.google.com/apis/design/resource_names. Format:
* `projects/{project}/locations/{location}/volumes/{volume}`
* @param Volume $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask The list of fields to update. The only currently
* supported fields are: 'labels'
* @return Operation
* @throws \Google\Service\Exception
*/
public function patch($name, Volume $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Operation::class);
}
/**
* RenameVolume sets a new name for a volume. Use with caution, previous names
* become immediately invalidated. (volumes.rename)
*
* @param string $name Required. The `name` field is used to identify the
* volume. Format: projects/{project}/locations/{location}/volumes/{volume}
* @param RenameVolumeRequest $postBody
* @param array $optParams Optional parameters.
* @return Volume
* @throws \Google\Service\Exception
*/
public function rename($name, RenameVolumeRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('rename', [$params], Volume::class);
}
/**
* Emergency Volume resize. (volumes.resize)
*
* @param string $volume Required. Volume to resize.
* @param ResizeVolumeRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function resize($volume, ResizeVolumeRequest $postBody, $optParams = [])
{
$params = ['volume' => $volume, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('resize', [$params], Operation::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsVolumes::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsVolumes');

View File

@@ -0,0 +1,89 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\EvictLunRequest;
use Google\Service\Baremetalsolution\ListLunsResponse;
use Google\Service\Baremetalsolution\Lun;
use Google\Service\Baremetalsolution\Operation;
/**
* The "luns" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $luns = $baremetalsolutionService->projects_locations_volumes_luns;
* </code>
*/
class ProjectsLocationsVolumesLuns extends \Google\Service\Resource
{
/**
* Skips lun's cooloff and deletes it now. Lun must be in cooloff state.
* (luns.evict)
*
* @param string $name Required. The name of the lun.
* @param EvictLunRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function evict($name, EvictLunRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('evict', [$params], Operation::class);
}
/**
* Get details of a single storage logical unit number(LUN). (luns.get)
*
* @param string $name Required. Name of the resource.
* @param array $optParams Optional parameters.
* @return Lun
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Lun::class);
}
/**
* List storage volume luns for given storage volume.
* (luns.listProjectsLocationsVolumesLuns)
*
* @param string $parent Required. Parent value for ListLunsRequest.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize Requested page size. The server might return fewer
* items than requested. If unspecified, server will pick an appropriate
* default.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListLunsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsVolumesLuns($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListLunsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsVolumesLuns::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsVolumesLuns');

View File

@@ -0,0 +1,125 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Baremetalsolution\Resource;
use Google\Service\Baremetalsolution\BaremetalsolutionEmpty;
use Google\Service\Baremetalsolution\ListVolumeSnapshotsResponse;
use Google\Service\Baremetalsolution\Operation;
use Google\Service\Baremetalsolution\RestoreVolumeSnapshotRequest;
use Google\Service\Baremetalsolution\VolumeSnapshot;
/**
* The "snapshots" collection of methods.
* Typical usage is:
* <code>
* $baremetalsolutionService = new Google\Service\Baremetalsolution(...);
* $snapshots = $baremetalsolutionService->projects_locations_volumes_snapshots;
* </code>
*/
class ProjectsLocationsVolumesSnapshots extends \Google\Service\Resource
{
/**
* Takes a snapshot of a boot volume. Returns INVALID_ARGUMENT if called for a
* non-boot volume. (snapshots.create)
*
* @param string $parent Required. The volume to snapshot.
* @param VolumeSnapshot $postBody
* @param array $optParams Optional parameters.
* @return VolumeSnapshot
* @throws \Google\Service\Exception
*/
public function create($parent, VolumeSnapshot $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], VolumeSnapshot::class);
}
/**
* Deletes a volume snapshot. Returns INVALID_ARGUMENT if called for a non-boot
* volume. (snapshots.delete)
*
* @param string $name Required. The name of the snapshot to delete.
* @param array $optParams Optional parameters.
* @return BaremetalsolutionEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], BaremetalsolutionEmpty::class);
}
/**
* Returns the specified snapshot resource. Returns INVALID_ARGUMENT if called
* for a non-boot volume. (snapshots.get)
*
* @param string $name Required. The name of the snapshot.
* @param array $optParams Optional parameters.
* @return VolumeSnapshot
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], VolumeSnapshot::class);
}
/**
* Retrieves the list of snapshots for the specified volume. Returns a response
* with an empty list of snapshots if called for a non-boot volume.
* (snapshots.listProjectsLocationsVolumesSnapshots)
*
* @param string $parent Required. Parent value for ListVolumesRequest.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize Requested page size. The server might return fewer
* items than requested. If unspecified, server will pick an appropriate
* default.
* @opt_param string pageToken A token identifying a page of results from the
* server.
* @return ListVolumeSnapshotsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsVolumesSnapshots($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListVolumeSnapshotsResponse::class);
}
/**
* Uses the specified snapshot to restore its parent volume. Returns
* INVALID_ARGUMENT if called for a non-boot volume.
* (snapshots.restoreVolumeSnapshot)
*
* @param string $volumeSnapshot Required. Name of the snapshot which will be
* used to restore its parent volume.
* @param RestoreVolumeSnapshotRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function restoreVolumeSnapshot($volumeSnapshot, RestoreVolumeSnapshotRequest $postBody, $optParams = [])
{
$params = ['volumeSnapshot' => $volumeSnapshot, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('restoreVolumeSnapshot', [$params], Operation::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsVolumesSnapshots::class, 'Google_Service_Baremetalsolution_Resource_ProjectsLocationsVolumesSnapshots');