Struct openstack::compute::NewKeyPair
source · pub struct NewKeyPair { /* private fields */ }
Expand description
A request to create a key pair.
Implementations§
source§impl NewKeyPair
impl NewKeyPair
sourcepub async fn create(self) -> Result<KeyPair>
pub async fn create(self) -> Result<KeyPair>
Request creation of a key pair.
This call fails immediately if no public_key is provided.
sourcepub async fn generate(self) -> Result<(KeyPair, String)>
pub async fn generate(self) -> Result<(KeyPair, String)>
Create a key pair, generating its public key.
Returns a new key pair and its private key.
sourcepub fn set_key_type(&mut self, value: KeyPairType)
pub fn set_key_type(&mut self, value: KeyPairType)
Set type of the key pair.
sourcepub fn with_key_type(self, value: KeyPairType) -> Self
pub fn with_key_type(self, value: KeyPairType) -> Self
Set type of the key pair.
sourcepub fn set_public_key<S: Into<String>>(&mut self, value: S)
pub fn set_public_key<S: Into<String>>(&mut self, value: S)
Set name of the key pair.
sourcepub fn with_public_key<S: Into<String>>(self, value: S) -> Self
pub fn with_public_key<S: Into<String>>(self, value: S) -> Self
Set name of the key pair.
Trait Implementations§
source§impl Clone for NewKeyPair
impl Clone for NewKeyPair
source§fn clone(&self) -> NewKeyPair
fn clone(&self) -> NewKeyPair
Returns a copy 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 more