#[non_exhaustive]pub struct CreateWorkstationRequest {
pub parent: String,
pub workstation_id: String,
pub workstation: Option<Workstation>,
pub validate_only: bool,
/* private fields */
}Expand description
Message for creating a CreateWorkstation.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.parent: StringRequired. Parent resource name.
workstation_id: StringRequired. ID to use for the workstation.
workstation: Option<Workstation>Required. Workstation to create.
validate_only: boolOptional. If set, validate the request and preview the review, but do not actually apply it.
Implementations§
Source§impl CreateWorkstationRequest
impl CreateWorkstationRequest
pub fn new() -> Self
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_workstation_id<T: Into<String>>(self, v: T) -> Self
pub fn set_workstation_id<T: Into<String>>(self, v: T) -> Self
Sets the value of workstation_id.
§Example
ⓘ
let x = CreateWorkstationRequest::new().set_workstation_id("example");Sourcepub fn set_workstation<T>(self, v: T) -> Selfwhere
T: Into<Workstation>,
pub fn set_workstation<T>(self, v: T) -> Selfwhere
T: Into<Workstation>,
Sets the value of workstation.
§Example
ⓘ
use google_cloud_workstations_v1::model::Workstation;
let x = CreateWorkstationRequest::new().set_workstation(Workstation::default()/* use setters */);Sourcepub fn set_or_clear_workstation<T>(self, v: Option<T>) -> Selfwhere
T: Into<Workstation>,
pub fn set_or_clear_workstation<T>(self, v: Option<T>) -> Selfwhere
T: Into<Workstation>,
Sets or clears the value of workstation.
§Example
ⓘ
use google_cloud_workstations_v1::model::Workstation;
let x = CreateWorkstationRequest::new().set_or_clear_workstation(Some(Workstation::default()/* use setters */));
let x = CreateWorkstationRequest::new().set_or_clear_workstation(None::<Workstation>);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 = CreateWorkstationRequest::new().set_validate_only(true);Trait Implementations§
Source§impl Clone for CreateWorkstationRequest
impl Clone for CreateWorkstationRequest
Source§fn clone(&self) -> CreateWorkstationRequest
fn clone(&self) -> CreateWorkstationRequest
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CreateWorkstationRequest
impl Debug for CreateWorkstationRequest
Source§impl Default for CreateWorkstationRequest
impl Default for CreateWorkstationRequest
Source§fn default() -> CreateWorkstationRequest
fn default() -> CreateWorkstationRequest
Returns the “default value” for a type. Read more
Source§impl Message for CreateWorkstationRequest
impl Message for CreateWorkstationRequest
Source§impl PartialEq for CreateWorkstationRequest
impl PartialEq for CreateWorkstationRequest
impl StructuralPartialEq for CreateWorkstationRequest
Auto Trait Implementations§
impl Freeze for CreateWorkstationRequest
impl RefUnwindSafe for CreateWorkstationRequest
impl Send for CreateWorkstationRequest
impl Sync for CreateWorkstationRequest
impl Unpin for CreateWorkstationRequest
impl UnwindSafe for CreateWorkstationRequest
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
Mutably borrows from an owned value. Read more