#[non_exhaustive]pub struct CreateInstanceConfigRequest {
pub parent: String,
pub instance_config_id: String,
pub instance_config: Option<InstanceConfig>,
pub validate_only: bool,
/* private fields */
}Expand description
The request for CreateInstanceConfig.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.parent: StringRequired. The name of the project in which to create the instance
configuration. Values are of the form projects/<project>.
instance_config_id: StringRequired. The ID of the instance configuration to create. Valid identifiers
are of the form custom-[-a-z0-9]*[a-z0-9] and must be between 2 and 64
characters in length. The custom- prefix is required to avoid name
conflicts with Google-managed configurations.
instance_config: Option<InstanceConfig>Required. The InstanceConfig proto of the configuration to create.
instance_config.name must be
<parent>/instanceConfigs/<instance_config_id>.
instance_config.base_config must be a Google-managed configuration name,
e.g. <parent>/instanceConfigs/us-east1, <parent>/instanceConfigs/nam3.
validate_only: boolAn option to validate, but not actually execute, a request, and provide the same response.
Implementations§
Source§impl CreateInstanceConfigRequest
impl CreateInstanceConfigRequest
Sourcepub fn set_parent<T: Into<String>>(self, v: T) -> Self
pub fn set_parent<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_instance_config_id<T: Into<String>>(self, v: T) -> Self
pub fn set_instance_config_id<T: Into<String>>(self, v: T) -> Self
Sets the value of instance_config_id.
§Example
let x = CreateInstanceConfigRequest::new().set_instance_config_id("example");Sourcepub fn set_instance_config<T>(self, v: T) -> Selfwhere
T: Into<InstanceConfig>,
pub fn set_instance_config<T>(self, v: T) -> Selfwhere
T: Into<InstanceConfig>,
Sets the value of instance_config.
§Example
use google_cloud_spanner_admin_instance_v1::model::InstanceConfig;
let x = CreateInstanceConfigRequest::new().set_instance_config(InstanceConfig::default()/* use setters */);Sourcepub fn set_or_clear_instance_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<InstanceConfig>,
pub fn set_or_clear_instance_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<InstanceConfig>,
Sets or clears the value of instance_config.
§Example
use google_cloud_spanner_admin_instance_v1::model::InstanceConfig;
let x = CreateInstanceConfigRequest::new().set_or_clear_instance_config(Some(InstanceConfig::default()/* use setters */));
let x = CreateInstanceConfigRequest::new().set_or_clear_instance_config(None::<InstanceConfig>);Sourcepub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
pub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
Sets the value of validate_only.
§Example
let x = CreateInstanceConfigRequest::new().set_validate_only(true);Trait Implementations§
Source§impl Clone for CreateInstanceConfigRequest
impl Clone for CreateInstanceConfigRequest
Source§fn clone(&self) -> CreateInstanceConfigRequest
fn clone(&self) -> CreateInstanceConfigRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CreateInstanceConfigRequest
impl Debug for CreateInstanceConfigRequest
Source§impl Default for CreateInstanceConfigRequest
impl Default for CreateInstanceConfigRequest
Source§fn default() -> CreateInstanceConfigRequest
fn default() -> CreateInstanceConfigRequest
impl StructuralPartialEq for CreateInstanceConfigRequest
Auto Trait Implementations§
impl Freeze for CreateInstanceConfigRequest
impl RefUnwindSafe for CreateInstanceConfigRequest
impl Send for CreateInstanceConfigRequest
impl Sync for CreateInstanceConfigRequest
impl Unpin for CreateInstanceConfigRequest
impl UnsafeUnpin for CreateInstanceConfigRequest
impl UnwindSafe for CreateInstanceConfigRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request