mirror of
https://github.com/OMGeeky/google-apis-rs.git
synced 2026-02-23 15:49:49 +01:00
make regen-apis
This commit is contained in:
@@ -4,12 +4,12 @@
|
||||
[package]
|
||||
|
||||
name = "google-baremetalsolution2"
|
||||
version = "5.0.4+20240228"
|
||||
version = "5.0.5+20240321"
|
||||
authors = ["Sebastian Thiel <byronimo@gmail.com>"]
|
||||
description = "A complete library to interact with baremetalsolution (protocol v2)"
|
||||
repository = "https://github.com/Byron/google-apis-rs/tree/main/gen/baremetalsolution2"
|
||||
homepage = "https://cloud.google.com/bare-metal"
|
||||
documentation = "https://docs.rs/google-baremetalsolution2/5.0.4+20240228"
|
||||
documentation = "https://docs.rs/google-baremetalsolution2/5.0.5+20240321"
|
||||
license = "MIT"
|
||||
keywords = ["baremetalsolution", "google", "protocol", "web", "api"]
|
||||
autobins = false
|
||||
@@ -18,12 +18,12 @@ edition = "2018"
|
||||
|
||||
[dependencies]
|
||||
anyhow = "^ 1.0"
|
||||
hyper-rustls = "0.24.0"
|
||||
hyper-rustls = "0.25.0"
|
||||
mime = "^ 0.3.0"
|
||||
serde = { version = "^ 1.0", features = ["derive"] }
|
||||
serde_json = "^ 1.0"
|
||||
itertools = "^ 0.10"
|
||||
google-apis-common = { path = "../../google-apis-common", version = "6.0" }
|
||||
google-apis-common = { path = "../../google-apis-common", version = "6.0.3" }
|
||||
hyper = "^ 0.14"
|
||||
http = "^0.2"
|
||||
tokio = "^1.0"
|
||||
|
||||
@@ -6,7 +6,7 @@ DO NOT EDIT !
|
||||
The MIT License (MIT)
|
||||
=====================
|
||||
|
||||
Copyright © `2015-2020` `Sebastian Thiel`
|
||||
Copyright 2015–2024 Sebastian Thiel
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
1976
gen/baremetalsolution2/src/api/enums.rs
Normal file
1976
gen/baremetalsolution2/src/api/enums.rs
Normal file
File diff suppressed because it is too large
Load Diff
114
gen/baremetalsolution2/src/api/hub.rs
Normal file
114
gen/baremetalsolution2/src/api/hub.rs
Normal file
@@ -0,0 +1,114 @@
|
||||
use super::*;
|
||||
|
||||
/// Central instance to access all Baremetalsolution related resource activities
|
||||
///
|
||||
/// # Examples
|
||||
///
|
||||
/// Instantiate a new hub
|
||||
///
|
||||
/// ```test_harness,no_run
|
||||
/// extern crate hyper;
|
||||
/// extern crate hyper_rustls;
|
||||
/// extern crate google_baremetalsolution2 as baremetalsolution2;
|
||||
/// use baremetalsolution2::api::Instance;
|
||||
/// use baremetalsolution2::{Result, Error};
|
||||
/// use baremetalsolution2::api::enums::*;
|
||||
/// # async fn dox() {
|
||||
/// use std::default::Default;
|
||||
/// use baremetalsolution2::{Baremetalsolution, oauth2, hyper, hyper_rustls, chrono, FieldMask};
|
||||
///
|
||||
/// // Get an ApplicationSecret instance by some means. It contains the `client_id` and
|
||||
/// // `client_secret`, among other things.
|
||||
/// let secret: oauth2::ApplicationSecret = Default::default();
|
||||
/// // Instantiate the authenticator. It will choose a suitable authentication flow for you,
|
||||
/// // unless you replace `None` with the desired Flow.
|
||||
/// // Provide your own `AuthenticatorDelegate` to adjust the way it operates and get feedback about
|
||||
/// // what's going on. You probably want to bring in your own `TokenStorage` to persist tokens and
|
||||
/// // retrieve them from storage.
|
||||
/// let auth = oauth2::InstalledFlowAuthenticator::builder(
|
||||
/// secret,
|
||||
/// oauth2::InstalledFlowReturnMethod::HTTPRedirect,
|
||||
/// ).build().await.unwrap();
|
||||
/// let mut hub = Baremetalsolution::new(hyper::Client::builder().build(hyper_rustls::HttpsConnectorBuilder::new().with_native_roots().unwrap().https_or_http().enable_http1().build()), auth);
|
||||
/// // As the method needs a request, you would usually fill it with the desired information
|
||||
/// // into the respective structure. Some of the parts shown here might not be applicable !
|
||||
/// // Values shown here are possibly random and not representative !
|
||||
/// let mut req = Instance::default();
|
||||
///
|
||||
/// // You can configure optional parameters by calling the respective setters at will, and
|
||||
/// // execute the final call using `doit()`.
|
||||
/// // Values shown here are possibly random and not representative !
|
||||
/// let result = hub.projects().locations_instances_patch(req, "name")
|
||||
/// .update_mask(FieldMask::new::<&str>(&[]))
|
||||
/// .doit().await;
|
||||
///
|
||||
/// match result {
|
||||
/// Err(e) => match e {
|
||||
/// // The Error enum provides details about what exactly happened.
|
||||
/// // You can also just use its `Debug`, `Display` or `Error` traits
|
||||
/// Error::HttpError(_)
|
||||
/// |Error::Io(_)
|
||||
/// |Error::MissingAPIKey
|
||||
/// |Error::MissingToken(_)
|
||||
/// |Error::Cancelled
|
||||
/// |Error::UploadSizeLimitExceeded(_, _)
|
||||
/// |Error::Failure(_)
|
||||
/// |Error::BadRequest(_)
|
||||
/// |Error::FieldClash(_)
|
||||
/// |Error::JsonDecodeError(_, _) => println!("{}", e),
|
||||
/// },
|
||||
/// Ok(res) => println!("Success: {:?}", res),
|
||||
/// }
|
||||
/// # }
|
||||
/// ```
|
||||
#[derive(Clone)]
|
||||
pub struct Baremetalsolution<S> {
|
||||
pub client: hyper::Client<S, hyper::body::Body>,
|
||||
pub auth: Box<dyn client::GetToken>,
|
||||
pub(super) _user_agent: String,
|
||||
pub(super) _base_url: String,
|
||||
pub(super) _root_url: String,
|
||||
}
|
||||
|
||||
impl<'a, S> client::Hub for Baremetalsolution<S> {}
|
||||
|
||||
impl<'a, S> Baremetalsolution<S> {
|
||||
|
||||
pub fn new<A: 'static + client::GetToken>(client: hyper::Client<S, hyper::body::Body>, auth: A) -> Baremetalsolution<S> {
|
||||
Baremetalsolution {
|
||||
client,
|
||||
auth: Box::new(auth),
|
||||
_user_agent: "google-api-rust-client/5.0.5".to_string(),
|
||||
_base_url: "https://baremetalsolution.googleapis.com/".to_string(),
|
||||
_root_url: "https://baremetalsolution.googleapis.com/".to_string(),
|
||||
}
|
||||
}
|
||||
|
||||
pub fn projects(&'a self) -> ProjectMethods<'a, S> {
|
||||
ProjectMethods { hub: &self }
|
||||
}
|
||||
|
||||
/// Set the user-agent header field to use in all requests to the server.
|
||||
/// It defaults to `google-api-rust-client/5.0.5`.
|
||||
///
|
||||
/// Returns the previously set user-agent.
|
||||
pub fn user_agent(&mut self, agent_name: String) -> String {
|
||||
mem::replace(&mut self._user_agent, agent_name)
|
||||
}
|
||||
|
||||
/// Set the base url to use in all requests to the server.
|
||||
/// It defaults to `https://baremetalsolution.googleapis.com/`.
|
||||
///
|
||||
/// Returns the previously set base url.
|
||||
pub fn base_url(&mut self, new_base_url: String) -> String {
|
||||
mem::replace(&mut self._base_url, new_base_url)
|
||||
}
|
||||
|
||||
/// Set the root url to use in all requests to the server.
|
||||
/// It defaults to `https://baremetalsolution.googleapis.com/`.
|
||||
///
|
||||
/// Returns the previously set root url.
|
||||
pub fn root_url(&mut self, new_root_url: String) -> String {
|
||||
mem::replace(&mut self._root_url, new_root_url)
|
||||
}
|
||||
}
|
||||
956
gen/baremetalsolution2/src/api/method_builders.rs
Normal file
956
gen/baremetalsolution2/src/api/method_builders.rs
Normal file
@@ -0,0 +1,956 @@
|
||||
use super::*;
|
||||
/// A builder providing access to all methods supported on *project* resources.
|
||||
/// It is not used directly, but through the [`Baremetalsolution`] hub.
|
||||
///
|
||||
/// # Example
|
||||
///
|
||||
/// Instantiate a resource builder
|
||||
///
|
||||
/// ```test_harness,no_run
|
||||
/// extern crate hyper;
|
||||
/// extern crate hyper_rustls;
|
||||
/// extern crate google_baremetalsolution2 as baremetalsolution2;
|
||||
///
|
||||
/// # async fn dox() {
|
||||
/// use std::default::Default;
|
||||
/// use baremetalsolution2::{Baremetalsolution, oauth2, hyper, hyper_rustls, chrono, FieldMask};
|
||||
///
|
||||
/// let secret: oauth2::ApplicationSecret = Default::default();
|
||||
/// let auth = oauth2::InstalledFlowAuthenticator::builder(
|
||||
/// secret,
|
||||
/// oauth2::InstalledFlowReturnMethod::HTTPRedirect,
|
||||
/// ).build().await.unwrap();
|
||||
/// let mut hub = Baremetalsolution::new(hyper::Client::builder().build(hyper_rustls::HttpsConnectorBuilder::new().with_native_roots().unwrap().https_or_http().enable_http1().build()), auth);
|
||||
/// // Usually you wouldn't bind this to a variable, but keep calling *CallBuilders*
|
||||
/// // like `locations_get(...)`, `locations_instances_detach_lun(...)`, `locations_instances_disable_interactive_serial_console(...)`, `locations_instances_enable_interactive_serial_console(...)`, `locations_instances_get(...)`, `locations_instances_list(...)`, `locations_instances_load_auth_info(...)`, `locations_instances_patch(...)`, `locations_instances_rename(...)`, `locations_instances_reset(...)`, `locations_instances_start(...)`, `locations_instances_stop(...)`, `locations_list(...)`, `locations_networks_get(...)`, `locations_networks_list(...)`, `locations_networks_list_network_usage(...)`, `locations_networks_patch(...)`, `locations_networks_rename(...)`, `locations_nfs_shares_create(...)`, `locations_nfs_shares_delete(...)`, `locations_nfs_shares_get(...)`, `locations_nfs_shares_list(...)`, `locations_nfs_shares_patch(...)`, `locations_nfs_shares_rename(...)`, `locations_operations_get(...)`, `locations_os_images_get(...)`, `locations_os_images_list(...)`, `locations_provisioning_configs_create(...)`, `locations_provisioning_configs_get(...)`, `locations_provisioning_configs_patch(...)`, `locations_provisioning_configs_submit(...)`, `locations_provisioning_quotas_list(...)`, `locations_ssh_keys_create(...)`, `locations_ssh_keys_delete(...)`, `locations_ssh_keys_list(...)`, `locations_volumes_evict(...)`, `locations_volumes_get(...)`, `locations_volumes_list(...)`, `locations_volumes_luns_evict(...)`, `locations_volumes_luns_get(...)`, `locations_volumes_luns_list(...)`, `locations_volumes_patch(...)`, `locations_volumes_rename(...)`, `locations_volumes_resize(...)`, `locations_volumes_snapshots_create(...)`, `locations_volumes_snapshots_delete(...)`, `locations_volumes_snapshots_get(...)`, `locations_volumes_snapshots_list(...)` and `locations_volumes_snapshots_restore_volume_snapshot(...)`
|
||||
/// // to build up your call.
|
||||
/// let rb = hub.projects();
|
||||
/// # }
|
||||
/// ```
|
||||
pub struct ProjectMethods<'a, S>
|
||||
where S: 'a {
|
||||
|
||||
pub(super) hub: &'a Baremetalsolution<S>,
|
||||
}
|
||||
|
||||
impl<'a, S> client::MethodsBuilder for ProjectMethods<'a, S> {}
|
||||
|
||||
impl<'a, S> ProjectMethods<'a, S> {
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Detach LUN from Instance.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `instance` - Required. Name of the instance.
|
||||
pub fn locations_instances_detach_lun(&self, request: DetachLunRequest, instance: &str) -> ProjectLocationInstanceDetachLunCall<'a, S> {
|
||||
ProjectLocationInstanceDetachLunCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_instance: instance.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Disable the interactive serial console feature on an instance.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_instances_disable_interactive_serial_console(&self, request: DisableInteractiveSerialConsoleRequest, name: &str) -> ProjectLocationInstanceDisableInteractiveSerialConsoleCall<'a, S> {
|
||||
ProjectLocationInstanceDisableInteractiveSerialConsoleCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Enable the interactive serial console feature on an instance.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_instances_enable_interactive_serial_console(&self, request: EnableInteractiveSerialConsoleRequest, name: &str) -> ProjectLocationInstanceEnableInteractiveSerialConsoleCall<'a, S> {
|
||||
ProjectLocationInstanceEnableInteractiveSerialConsoleCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get details about a single server.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_instances_get(&self, name: &str) -> ProjectLocationInstanceGetCall<'a, S> {
|
||||
ProjectLocationInstanceGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// List servers in a given project and location.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListInstancesRequest.
|
||||
pub fn locations_instances_list(&self, parent: &str) -> ProjectLocationInstanceListCall<'a, S> {
|
||||
ProjectLocationInstanceListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_filter: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Load auth info for a server.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the server.
|
||||
pub fn locations_instances_load_auth_info(&self, name: &str) -> ProjectLocationInstanceLoadAuthInfoCall<'a, S> {
|
||||
ProjectLocationInstanceLoadAuthInfoCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Update details of a single server.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `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}`
|
||||
pub fn locations_instances_patch(&self, request: Instance, name: &str) -> ProjectLocationInstancePatchCall<'a, S> {
|
||||
ProjectLocationInstancePatchCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_update_mask: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// RenameInstance sets a new name for an instance. Use with caution, previous names become immediately invalidated.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. The `name` field is used to identify the instance. Format: projects/{project}/locations/{location}/instances/{instance}
|
||||
pub fn locations_instances_rename(&self, request: RenameInstanceRequest, name: &str) -> ProjectLocationInstanceRenameCall<'a, S> {
|
||||
ProjectLocationInstanceRenameCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Perform an ungraceful, hard reset on a server. Equivalent to shutting the power off and then turning it back on.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_instances_reset(&self, request: ResetInstanceRequest, name: &str) -> ProjectLocationInstanceResetCall<'a, S> {
|
||||
ProjectLocationInstanceResetCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Starts a server that was shutdown.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_instances_start(&self, request: StartInstanceRequest, name: &str) -> ProjectLocationInstanceStartCall<'a, S> {
|
||||
ProjectLocationInstanceStartCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Stop a running server.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_instances_stop(&self, request: StopInstanceRequest, name: &str) -> ProjectLocationInstanceStopCall<'a, S> {
|
||||
ProjectLocationInstanceStopCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get details of a single network.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_networks_get(&self, name: &str) -> ProjectLocationNetworkGetCall<'a, S> {
|
||||
ProjectLocationNetworkGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// List network in a given project and location.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListNetworksRequest.
|
||||
pub fn locations_networks_list(&self, parent: &str) -> ProjectLocationNetworkListCall<'a, S> {
|
||||
ProjectLocationNetworkListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_filter: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// List all Networks (and used IPs for each Network) in the vendor account associated with the specified project.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `location` - Required. Parent value (project and location).
|
||||
pub fn locations_networks_list_network_usage(&self, location: &str) -> ProjectLocationNetworkListNetworkUsageCall<'a, S> {
|
||||
ProjectLocationNetworkListNetworkUsageCall {
|
||||
hub: self.hub,
|
||||
_location: location.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Update details of a single network.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `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}`
|
||||
pub fn locations_networks_patch(&self, request: Network, name: &str) -> ProjectLocationNetworkPatchCall<'a, S> {
|
||||
ProjectLocationNetworkPatchCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_update_mask: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// RenameNetwork sets a new name for a network. Use with caution, previous names become immediately invalidated.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. The `name` field is used to identify the network. Format: projects/{project}/locations/{location}/networks/{network}
|
||||
pub fn locations_networks_rename(&self, request: RenameNetworkRequest, name: &str) -> ProjectLocationNetworkRenameCall<'a, S> {
|
||||
ProjectLocationNetworkRenameCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Create an NFS share.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `parent` - Required. The parent project and location.
|
||||
pub fn locations_nfs_shares_create(&self, request: NfsShare, parent: &str) -> ProjectLocationNfsShareCreateCall<'a, S> {
|
||||
ProjectLocationNfsShareCreateCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_parent: parent.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Delete an NFS share. The underlying volume is automatically deleted.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. The name of the NFS share to delete.
|
||||
pub fn locations_nfs_shares_delete(&self, name: &str) -> ProjectLocationNfsShareDeleteCall<'a, S> {
|
||||
ProjectLocationNfsShareDeleteCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get details of a single NFS share.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_nfs_shares_get(&self, name: &str) -> ProjectLocationNfsShareGetCall<'a, S> {
|
||||
ProjectLocationNfsShareGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// List NFS shares.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListNfsSharesRequest.
|
||||
pub fn locations_nfs_shares_list(&self, parent: &str) -> ProjectLocationNfsShareListCall<'a, S> {
|
||||
ProjectLocationNfsShareListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_filter: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Update details of a single NFS share.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Immutable. The name of the NFS share.
|
||||
pub fn locations_nfs_shares_patch(&self, request: NfsShare, name: &str) -> ProjectLocationNfsSharePatchCall<'a, S> {
|
||||
ProjectLocationNfsSharePatchCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_update_mask: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// RenameNfsShare sets a new name for an nfsshare. Use with caution, previous names become immediately invalidated.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. The `name` field is used to identify the nfsshare. Format: projects/{project}/locations/{location}/nfsshares/{nfsshare}
|
||||
pub fn locations_nfs_shares_rename(&self, request: RenameNfsShareRequest, name: &str) -> ProjectLocationNfsShareRenameCall<'a, S> {
|
||||
ProjectLocationNfsShareRenameCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get details about an operation.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - The name of the operation resource.
|
||||
pub fn locations_operations_get(&self, name: &str) -> ProjectLocationOperationGetCall<'a, S> {
|
||||
ProjectLocationOperationGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get details of a single OS image.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the OS image.
|
||||
pub fn locations_os_images_get(&self, name: &str) -> ProjectLocationOsImageGetCall<'a, S> {
|
||||
ProjectLocationOsImageGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Retrieves the list of OS images which are currently approved.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListOSImagesRequest.
|
||||
pub fn locations_os_images_list(&self, parent: &str) -> ProjectLocationOsImageListCall<'a, S> {
|
||||
ProjectLocationOsImageListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Create new ProvisioningConfig.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `parent` - Required. The parent project and location containing the ProvisioningConfig.
|
||||
pub fn locations_provisioning_configs_create(&self, request: ProvisioningConfig, parent: &str) -> ProjectLocationProvisioningConfigCreateCall<'a, S> {
|
||||
ProjectLocationProvisioningConfigCreateCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_parent: parent.to_string(),
|
||||
_email: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get ProvisioningConfig by name.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the ProvisioningConfig.
|
||||
pub fn locations_provisioning_configs_get(&self, name: &str) -> ProjectLocationProvisioningConfigGetCall<'a, S> {
|
||||
ProjectLocationProvisioningConfigGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Update existing ProvisioningConfig.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Output only. The system-generated name of the provisioning config. This follows the UUID format.
|
||||
pub fn locations_provisioning_configs_patch(&self, request: ProvisioningConfig, name: &str) -> ProjectLocationProvisioningConfigPatchCall<'a, S> {
|
||||
ProjectLocationProvisioningConfigPatchCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_update_mask: Default::default(),
|
||||
_email: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Submit a provisiong configuration for a given project.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `parent` - Required. The parent project and location containing the ProvisioningConfig.
|
||||
pub fn locations_provisioning_configs_submit(&self, request: SubmitProvisioningConfigRequest, parent: &str) -> ProjectLocationProvisioningConfigSubmitCall<'a, S> {
|
||||
ProjectLocationProvisioningConfigSubmitCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_parent: parent.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// List the budget details to provision resources on a given project.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListProvisioningQuotasRequest.
|
||||
pub fn locations_provisioning_quotas_list(&self, parent: &str) -> ProjectLocationProvisioningQuotaListCall<'a, S> {
|
||||
ProjectLocationProvisioningQuotaListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Register a public SSH key in the specified project for use with the interactive serial console feature.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `parent` - Required. The parent containing the SSH keys.
|
||||
pub fn locations_ssh_keys_create(&self, request: SSHKey, parent: &str) -> ProjectLocationSshKeyCreateCall<'a, S> {
|
||||
ProjectLocationSshKeyCreateCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_parent: parent.to_string(),
|
||||
_ssh_key_id: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Deletes a public SSH key registered in the specified project.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. The name of the SSH key to delete. Currently, the only valid value for the location is "global".
|
||||
pub fn locations_ssh_keys_delete(&self, name: &str) -> ProjectLocationSshKeyDeleteCall<'a, S> {
|
||||
ProjectLocationSshKeyDeleteCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Lists the public SSH keys registered for the specified project. These SSH keys are used only for the interactive serial console feature.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. The parent containing the SSH keys. Currently, the only valid value for the location is "global".
|
||||
pub fn locations_ssh_keys_list(&self, parent: &str) -> ProjectLocationSshKeyListCall<'a, S> {
|
||||
ProjectLocationSshKeyListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Skips lun's cooloff and deletes it now. Lun must be in cooloff state.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. The name of the lun.
|
||||
pub fn locations_volumes_luns_evict(&self, request: EvictLunRequest, name: &str) -> ProjectLocationVolumeLunEvictCall<'a, S> {
|
||||
ProjectLocationVolumeLunEvictCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get details of a single storage logical unit number(LUN).
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_volumes_luns_get(&self, name: &str) -> ProjectLocationVolumeLunGetCall<'a, S> {
|
||||
ProjectLocationVolumeLunGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// List storage volume luns for given storage volume.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListLunsRequest.
|
||||
pub fn locations_volumes_luns_list(&self, parent: &str) -> ProjectLocationVolumeLunListCall<'a, S> {
|
||||
ProjectLocationVolumeLunListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Takes a snapshot of a boot volume. Returns INVALID_ARGUMENT if called for a non-boot volume.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `parent` - Required. The volume to snapshot.
|
||||
pub fn locations_volumes_snapshots_create(&self, request: VolumeSnapshot, parent: &str) -> ProjectLocationVolumeSnapshotCreateCall<'a, S> {
|
||||
ProjectLocationVolumeSnapshotCreateCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_parent: parent.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Deletes a volume snapshot. Returns INVALID_ARGUMENT if called for a non-boot volume.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. The name of the snapshot to delete.
|
||||
pub fn locations_volumes_snapshots_delete(&self, name: &str) -> ProjectLocationVolumeSnapshotDeleteCall<'a, S> {
|
||||
ProjectLocationVolumeSnapshotDeleteCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Returns the specified snapshot resource. Returns INVALID_ARGUMENT if called for a non-boot volume.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. The name of the snapshot.
|
||||
pub fn locations_volumes_snapshots_get(&self, name: &str) -> ProjectLocationVolumeSnapshotGetCall<'a, S> {
|
||||
ProjectLocationVolumeSnapshotGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// 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.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListVolumesRequest.
|
||||
pub fn locations_volumes_snapshots_list(&self, parent: &str) -> ProjectLocationVolumeSnapshotListCall<'a, S> {
|
||||
ProjectLocationVolumeSnapshotListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Uses the specified snapshot to restore its parent volume. Returns INVALID_ARGUMENT if called for a non-boot volume.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `volumeSnapshot` - Required. Name of the snapshot which will be used to restore its parent volume.
|
||||
pub fn locations_volumes_snapshots_restore_volume_snapshot(&self, request: RestoreVolumeSnapshotRequest, volume_snapshot: &str) -> ProjectLocationVolumeSnapshotRestoreVolumeSnapshotCall<'a, S> {
|
||||
ProjectLocationVolumeSnapshotRestoreVolumeSnapshotCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_volume_snapshot: volume_snapshot.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Skips volume's cooloff and deletes it now. Volume must be in cooloff state.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. The name of the Volume.
|
||||
pub fn locations_volumes_evict(&self, request: EvictVolumeRequest, name: &str) -> ProjectLocationVolumeEvictCall<'a, S> {
|
||||
ProjectLocationVolumeEvictCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Get details of a single storage volume.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Required. Name of the resource.
|
||||
pub fn locations_volumes_get(&self, name: &str) -> ProjectLocationVolumeGetCall<'a, S> {
|
||||
ProjectLocationVolumeGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// List storage volumes in a given project and location.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `parent` - Required. Parent value for ListVolumesRequest.
|
||||
pub fn locations_volumes_list(&self, parent: &str) -> ProjectLocationVolumeListCall<'a, S> {
|
||||
ProjectLocationVolumeListCall {
|
||||
hub: self.hub,
|
||||
_parent: parent.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_filter: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Update details of a single storage volume.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `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}`
|
||||
pub fn locations_volumes_patch(&self, request: Volume, name: &str) -> ProjectLocationVolumePatchCall<'a, S> {
|
||||
ProjectLocationVolumePatchCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_update_mask: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// RenameVolume sets a new name for a volume. Use with caution, previous names become immediately invalidated.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `name` - Required. The `name` field is used to identify the volume. Format: projects/{project}/locations/{location}/volumes/{volume}
|
||||
pub fn locations_volumes_rename(&self, request: RenameVolumeRequest, name: &str) -> ProjectLocationVolumeRenameCall<'a, S> {
|
||||
ProjectLocationVolumeRenameCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Emergency Volume resize.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `request` - No description provided.
|
||||
/// * `volume` - Required. Volume to resize.
|
||||
pub fn locations_volumes_resize(&self, request: ResizeVolumeRequest, volume: &str) -> ProjectLocationVolumeResizeCall<'a, S> {
|
||||
ProjectLocationVolumeResizeCall {
|
||||
hub: self.hub,
|
||||
_request: request,
|
||||
_volume: volume.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Gets information about a location.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - Resource name for the location.
|
||||
pub fn locations_get(&self, name: &str) -> ProjectLocationGetCall<'a, S> {
|
||||
ProjectLocationGetCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
/// Create a builder to help you perform the following task:
|
||||
///
|
||||
/// Lists information about the supported locations for this service.
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `name` - The resource that owns the locations collection, if applicable.
|
||||
pub fn locations_list(&self, name: &str) -> ProjectLocationListCall<'a, S> {
|
||||
ProjectLocationListCall {
|
||||
hub: self.hub,
|
||||
_name: name.to_string(),
|
||||
_page_token: Default::default(),
|
||||
_page_size: Default::default(),
|
||||
_filter: Default::default(),
|
||||
_delegate: Default::default(),
|
||||
_additional_params: Default::default(),
|
||||
_scopes: Default::default(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
35
gen/baremetalsolution2/src/api/mod.rs
Normal file
35
gen/baremetalsolution2/src/api/mod.rs
Normal file
@@ -0,0 +1,35 @@
|
||||
use std::collections::HashMap;
|
||||
use std::cell::RefCell;
|
||||
use std::default::Default;
|
||||
use std::collections::BTreeSet;
|
||||
use std::error::Error as StdError;
|
||||
use serde_json as json;
|
||||
use std::io;
|
||||
use std::fs;
|
||||
use std::mem;
|
||||
|
||||
use hyper::client::connect;
|
||||
use tokio::io::{AsyncRead, AsyncWrite};
|
||||
use tokio::time::sleep;
|
||||
use tower_service;
|
||||
use serde::{Serialize, Deserialize};
|
||||
|
||||
use crate::{client, client::GetToken, client::serde_with};
|
||||
|
||||
mod utilities;
|
||||
pub use utilities::*;
|
||||
|
||||
mod hub;
|
||||
pub use hub::*;
|
||||
|
||||
mod schemas;
|
||||
pub use schemas::*;
|
||||
|
||||
mod method_builders;
|
||||
pub use method_builders::*;
|
||||
|
||||
mod call_builders;
|
||||
pub use call_builders::*;
|
||||
|
||||
pub mod enums;
|
||||
pub(crate) use enums::*;
|
||||
1918
gen/baremetalsolution2/src/api/schemas.rs
Normal file
1918
gen/baremetalsolution2/src/api/schemas.rs
Normal file
File diff suppressed because it is too large
Load Diff
24
gen/baremetalsolution2/src/api/utilities.rs
Normal file
24
gen/baremetalsolution2/src/api/utilities.rs
Normal file
@@ -0,0 +1,24 @@
|
||||
use super::*;
|
||||
/// Identifies the an OAuth2 authorization scope.
|
||||
/// A scope is needed when requesting an
|
||||
/// [authorization token](https://developers.google.com/youtube/v3/guides/authentication).
|
||||
#[derive(PartialEq, Eq, Hash, Debug, Clone)]
|
||||
pub enum Scope {
|
||||
/// See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.
|
||||
CloudPlatform,
|
||||
}
|
||||
|
||||
impl AsRef<str> for Scope {
|
||||
fn as_ref(&self) -> &str {
|
||||
match *self {
|
||||
Scope::CloudPlatform => "https://www.googleapis.com/auth/cloud-platform",
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Default for Scope {
|
||||
fn default() -> Scope {
|
||||
Scope::CloudPlatform
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,14 +2,14 @@
|
||||
// This file was generated automatically from 'src/generator/templates/api/lib.rs.mako'
|
||||
// DO NOT EDIT !
|
||||
|
||||
//! This documentation was generated from *baremetalsolution* crate version *5.0.4+20240228*, where *20240228* is the exact revision of the *baremetalsolution:v2* schema built by the [mako](http://www.makotemplates.org/) code generator *v5.0.4*.
|
||||
//! This documentation was generated from *baremetalsolution* crate version *5.0.5+20240321*, where *20240321* is the exact revision of the *baremetalsolution:v2* schema built by the [mako](http://www.makotemplates.org/) code generator *v5.0.5*.
|
||||
//!
|
||||
//! Everything else about the *baremetalsolution* *v2* API can be found at the
|
||||
//! [official documentation site](https://cloud.google.com/bare-metal).
|
||||
//! The original source code is [on github](https://github.com/Byron/google-apis-rs/tree/main/gen/baremetalsolution2).
|
||||
//! # Features
|
||||
//!
|
||||
//! Handle the following *Resources* with ease from the central [hub](Baremetalsolution) ...
|
||||
//! Handle the following *Resources* with ease from the central [hub](Baremetalsolution) ...
|
||||
//!
|
||||
//! * projects
|
||||
//! * [*locations get*](api::ProjectLocationGetCall), [*locations instances detach lun*](api::ProjectLocationInstanceDetachLunCall), [*locations instances disable interactive serial console*](api::ProjectLocationInstanceDisableInteractiveSerialConsoleCall), [*locations instances enable interactive serial console*](api::ProjectLocationInstanceEnableInteractiveSerialConsoleCall), [*locations instances get*](api::ProjectLocationInstanceGetCall), [*locations instances list*](api::ProjectLocationInstanceListCall), [*locations instances load auth info*](api::ProjectLocationInstanceLoadAuthInfoCall), [*locations instances patch*](api::ProjectLocationInstancePatchCall), [*locations instances rename*](api::ProjectLocationInstanceRenameCall), [*locations instances reset*](api::ProjectLocationInstanceResetCall), [*locations instances start*](api::ProjectLocationInstanceStartCall), [*locations instances stop*](api::ProjectLocationInstanceStopCall), [*locations list*](api::ProjectLocationListCall), [*locations networks get*](api::ProjectLocationNetworkGetCall), [*locations networks list*](api::ProjectLocationNetworkListCall), [*locations networks list network usage*](api::ProjectLocationNetworkListNetworkUsageCall), [*locations networks patch*](api::ProjectLocationNetworkPatchCall), [*locations networks rename*](api::ProjectLocationNetworkRenameCall), [*locations nfs shares create*](api::ProjectLocationNfsShareCreateCall), [*locations nfs shares delete*](api::ProjectLocationNfsShareDeleteCall), [*locations nfs shares get*](api::ProjectLocationNfsShareGetCall), [*locations nfs shares list*](api::ProjectLocationNfsShareListCall), [*locations nfs shares patch*](api::ProjectLocationNfsSharePatchCall), [*locations nfs shares rename*](api::ProjectLocationNfsShareRenameCall), [*locations operations get*](api::ProjectLocationOperationGetCall), [*locations os images get*](api::ProjectLocationOsImageGetCall), [*locations os images list*](api::ProjectLocationOsImageListCall), [*locations provisioning configs create*](api::ProjectLocationProvisioningConfigCreateCall), [*locations provisioning configs get*](api::ProjectLocationProvisioningConfigGetCall), [*locations provisioning configs patch*](api::ProjectLocationProvisioningConfigPatchCall), [*locations provisioning configs submit*](api::ProjectLocationProvisioningConfigSubmitCall), [*locations provisioning quotas list*](api::ProjectLocationProvisioningQuotaListCall), [*locations ssh keys create*](api::ProjectLocationSshKeyCreateCall), [*locations ssh keys delete*](api::ProjectLocationSshKeyDeleteCall), [*locations ssh keys list*](api::ProjectLocationSshKeyListCall), [*locations volumes evict*](api::ProjectLocationVolumeEvictCall), [*locations volumes get*](api::ProjectLocationVolumeGetCall), [*locations volumes list*](api::ProjectLocationVolumeListCall), [*locations volumes luns evict*](api::ProjectLocationVolumeLunEvictCall), [*locations volumes luns get*](api::ProjectLocationVolumeLunGetCall), [*locations volumes luns list*](api::ProjectLocationVolumeLunListCall), [*locations volumes patch*](api::ProjectLocationVolumePatchCall), [*locations volumes rename*](api::ProjectLocationVolumeRenameCall), [*locations volumes resize*](api::ProjectLocationVolumeResizeCall), [*locations volumes snapshots create*](api::ProjectLocationVolumeSnapshotCreateCall), [*locations volumes snapshots delete*](api::ProjectLocationVolumeSnapshotDeleteCall), [*locations volumes snapshots get*](api::ProjectLocationVolumeSnapshotGetCall), [*locations volumes snapshots list*](api::ProjectLocationVolumeSnapshotListCall) and [*locations volumes snapshots restore volume snapshot*](api::ProjectLocationVolumeSnapshotRestoreVolumeSnapshotCall)
|
||||
@@ -66,8 +66,8 @@
|
||||
//! let r = hub.projects().locations_volumes_resize(...).doit().await
|
||||
//! ```
|
||||
//!
|
||||
//! The `resource()` and `activity(...)` calls create [builders][builder-pattern]. The second one dealing with `Activities`
|
||||
//! supports various methods to configure the impending operation (not shown here). It is made such that all required arguments have to be
|
||||
//! The `resource()` and `activity(...)` calls create [builders][builder-pattern]. The second one dealing with `Activities`
|
||||
//! supports various methods to configure the impending operation (not shown here). It is made such that all required arguments have to be
|
||||
//! specified right away (i.e. `(...)`), whereas all optional ones can be [build up][builder-pattern] as desired.
|
||||
//! The `doit()` method performs the actual communication with the server and returns the respective result.
|
||||
//!
|
||||
@@ -92,23 +92,24 @@
|
||||
//! extern crate google_baremetalsolution2 as baremetalsolution2;
|
||||
//! use baremetalsolution2::api::Instance;
|
||||
//! use baremetalsolution2::{Result, Error};
|
||||
//! use baremetalsolution2::api::enums::*;
|
||||
//! # async fn dox() {
|
||||
//! use std::default::Default;
|
||||
//! use baremetalsolution2::{Baremetalsolution, oauth2, hyper, hyper_rustls, chrono, FieldMask};
|
||||
//!
|
||||
//! // Get an ApplicationSecret instance by some means. It contains the `client_id` and
|
||||
//! // Get an ApplicationSecret instance by some means. It contains the `client_id` and
|
||||
//! // `client_secret`, among other things.
|
||||
//! let secret: oauth2::ApplicationSecret = Default::default();
|
||||
//! // Instantiate the authenticator. It will choose a suitable authentication flow for you,
|
||||
//! // Instantiate the authenticator. It will choose a suitable authentication flow for you,
|
||||
//! // unless you replace `None` with the desired Flow.
|
||||
//! // Provide your own `AuthenticatorDelegate` to adjust the way it operates and get feedback about
|
||||
//! // Provide your own `AuthenticatorDelegate` to adjust the way it operates and get feedback about
|
||||
//! // what's going on. You probably want to bring in your own `TokenStorage` to persist tokens and
|
||||
//! // retrieve them from storage.
|
||||
//! let auth = oauth2::InstalledFlowAuthenticator::builder(
|
||||
//! secret,
|
||||
//! oauth2::InstalledFlowReturnMethod::HTTPRedirect,
|
||||
//! ).build().await.unwrap();
|
||||
//! let mut hub = Baremetalsolution::new(hyper::Client::builder().build(hyper_rustls::HttpsConnectorBuilder::new().with_native_roots().https_or_http().enable_http1().build()), auth);
|
||||
//! let mut hub = Baremetalsolution::new(hyper::Client::builder().build(hyper_rustls::HttpsConnectorBuilder::new().with_native_roots().unwrap().https_or_http().enable_http1().build()), auth);
|
||||
//! // As the method needs a request, you would usually fill it with the desired information
|
||||
//! // into the respective structure. Some of the parts shown here might not be applicable !
|
||||
//! // Values shown here are possibly random and not representative !
|
||||
@@ -118,7 +119,7 @@
|
||||
//! // execute the final call using `doit()`.
|
||||
//! // Values shown here are possibly random and not representative !
|
||||
//! let result = hub.projects().locations_instances_patch(req, "name")
|
||||
//! .update_mask(&Default::default())
|
||||
//! .update_mask(FieldMask::new::<&str>(&[]))
|
||||
//! .doit().await;
|
||||
//!
|
||||
//! match result {
|
||||
@@ -143,10 +144,10 @@
|
||||
//! ## Handling Errors
|
||||
//!
|
||||
//! All errors produced by the system are provided either as [Result](client::Result) enumeration as return value of
|
||||
//! the doit() methods, or handed as possibly intermediate results to either the
|
||||
//! the doit() methods, or handed as possibly intermediate results to either the
|
||||
//! [Hub Delegate](client::Delegate), or the [Authenticator Delegate](https://docs.rs/yup-oauth2/*/yup_oauth2/trait.AuthenticatorDelegate.html).
|
||||
//!
|
||||
//! When delegates handle errors or intermediate values, they may have a chance to instruct the system to retry. This
|
||||
//! When delegates handle errors or intermediate values, they may have a chance to instruct the system to retry. This
|
||||
//! makes the system potentially resilient to all kinds of errors.
|
||||
//!
|
||||
//! ## Uploads and Downloads
|
||||
@@ -156,25 +157,25 @@
|
||||
//! You can see it as meta-data for the actual media. To trigger a media download, you will have to set up the builder by making
|
||||
//! this call: `.param("alt", "media")`.
|
||||
//!
|
||||
//! Methods supporting uploads can do so using up to 2 different protocols:
|
||||
//! *simple* and *resumable*. The distinctiveness of each is represented by customized
|
||||
//! Methods supporting uploads can do so using up to 2 different protocols:
|
||||
//! *simple* and *resumable*. The distinctiveness of each is represented by customized
|
||||
//! `doit(...)` methods, which are then named `upload(...)` and `upload_resumable(...)` respectively.
|
||||
//!
|
||||
//! ## Customization and Callbacks
|
||||
//!
|
||||
//! You may alter the way an `doit()` method is called by providing a [delegate](client::Delegate) to the
|
||||
//! [Method Builder](client::CallBuilder) before making the final `doit()` call.
|
||||
//! Respective methods will be called to provide progress information, as well as determine whether the system should
|
||||
//! You may alter the way an `doit()` method is called by providing a [delegate](client::Delegate) to the
|
||||
//! [Method Builder](client::CallBuilder) before making the final `doit()` call.
|
||||
//! Respective methods will be called to provide progress information, as well as determine whether the system should
|
||||
//! retry on failure.
|
||||
//!
|
||||
//! The [delegate trait](client::Delegate) is default-implemented, allowing you to customize it with minimal effort.
|
||||
//!
|
||||
//! ## Optional Parts in Server-Requests
|
||||
//!
|
||||
//! All structures provided by this library are made to be [encodable](client::RequestValue) and
|
||||
//! [decodable](client::ResponseResult) via *json*. Optionals are used to indicate that partial requests are responses
|
||||
//! All structures provided by this library are made to be [encodable](client::RequestValue) and
|
||||
//! [decodable](client::ResponseResult) via *json*. Optionals are used to indicate that partial requests are responses
|
||||
//! are valid.
|
||||
//! Most optionals are are considered [Parts](client::Part) which are identifiable by name, which will be sent to
|
||||
//! Most optionals are are considered [Parts](client::Part) which are identifiable by name, which will be sent to
|
||||
//! the server to indicate either the set parts of the request or the desired parts in the response.
|
||||
//!
|
||||
//! ## Builder Arguments
|
||||
|
||||
Reference in New Issue
Block a user