#[non_exhaustive]pub struct CreateSshPublicKeyRequest {
pub parent: String,
pub ssh_public_key: Option<SshPublicKey>,
/* private fields */
}Expand description
A request message for creating an SSH public key.
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. The unique ID for the user in format users/{user}.
ssh_public_key: Option<SshPublicKey>Required. The SSH public key and expiration time.
Implementations§
Source§impl CreateSshPublicKeyRequest
impl CreateSshPublicKeyRequest
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_ssh_public_key<T>(self, v: T) -> Selfwhere
T: Into<SshPublicKey>,
pub fn set_ssh_public_key<T>(self, v: T) -> Selfwhere
T: Into<SshPublicKey>,
Sets the value of ssh_public_key.
§Example
ⓘ
use google_cloud_oslogin_common::model::SshPublicKey;
let x = CreateSshPublicKeyRequest::new().set_ssh_public_key(SshPublicKey::default()/* use setters */);Sourcepub fn set_or_clear_ssh_public_key<T>(self, v: Option<T>) -> Selfwhere
T: Into<SshPublicKey>,
pub fn set_or_clear_ssh_public_key<T>(self, v: Option<T>) -> Selfwhere
T: Into<SshPublicKey>,
Sets or clears the value of ssh_public_key.
§Example
ⓘ
use google_cloud_oslogin_common::model::SshPublicKey;
let x = CreateSshPublicKeyRequest::new().set_or_clear_ssh_public_key(Some(SshPublicKey::default()/* use setters */));
let x = CreateSshPublicKeyRequest::new().set_or_clear_ssh_public_key(None::<SshPublicKey>);Trait Implementations§
Source§impl Clone for CreateSshPublicKeyRequest
impl Clone for CreateSshPublicKeyRequest
Source§fn clone(&self) -> CreateSshPublicKeyRequest
fn clone(&self) -> CreateSshPublicKeyRequest
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 CreateSshPublicKeyRequest
impl Debug for CreateSshPublicKeyRequest
Source§impl Default for CreateSshPublicKeyRequest
impl Default for CreateSshPublicKeyRequest
Source§fn default() -> CreateSshPublicKeyRequest
fn default() -> CreateSshPublicKeyRequest
Returns the “default value” for a type. Read more
Source§impl Message for CreateSshPublicKeyRequest
impl Message for CreateSshPublicKeyRequest
Source§impl PartialEq for CreateSshPublicKeyRequest
impl PartialEq for CreateSshPublicKeyRequest
Source§fn eq(&self, other: &CreateSshPublicKeyRequest) -> bool
fn eq(&self, other: &CreateSshPublicKeyRequest) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for CreateSshPublicKeyRequest
Auto Trait Implementations§
impl Freeze for CreateSshPublicKeyRequest
impl RefUnwindSafe for CreateSshPublicKeyRequest
impl Send for CreateSshPublicKeyRequest
impl Sync for CreateSshPublicKeyRequest
impl Unpin for CreateSshPublicKeyRequest
impl UnsafeUnpin for CreateSshPublicKeyRequest
impl UnwindSafe for CreateSshPublicKeyRequest
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