[][src]Struct pgp::composed::key::SecretKeyParamsBuilder

pub struct SecretKeyParamsBuilder { /* fields omitted */ }

Builder for SecretKeyParams.

Methods

impl SecretKeyParamsBuilder[src]

pub fn key_type(&mut self, value: KeyType) -> &mut Self[src]

pub fn can_sign(&mut self, value: bool) -> &mut Self[src]

pub fn can_create_certificates(&mut self, value: bool) -> &mut Self[src]

pub fn can_encrypt(&mut self, value: bool) -> &mut Self[src]

pub fn preferred_symmetric_algorithms(
    &mut self,
    value: SmallVec<[SymmetricKeyAlgorithm; 8]>
) -> &mut Self
[src]

List of symmetric algorithms that indicate which algorithms the key holder prefers to use.

pub fn preferred_hash_algorithms(
    &mut self,
    value: SmallVec<[HashAlgorithm; 8]>
) -> &mut Self
[src]

List of hash algorithms that indicate which algorithms the key holder prefers to use.

pub fn preferred_compression_algorithms(
    &mut self,
    value: SmallVec<[CompressionAlgorithm; 8]>
) -> &mut Self
[src]

List of compression algorithms that indicate which algorithms the key holder prefers to use.

pub fn revocation_key(&mut self, value: Option<RevocationKey>) -> &mut Self[src]

pub fn primary_user_id(&mut self, value: String) -> &mut Self[src]

pub fn user_ids(&mut self, value: Vec<String>) -> &mut Self[src]

pub fn user_attributes(&mut self, value: Vec<UserAttribute>) -> &mut Self[src]

pub fn passphrase(&mut self, value: Option<String>) -> &mut Self[src]

pub fn created_at(&mut self, value: DateTime<Utc>) -> &mut Self[src]

pub fn packet_version(&mut self, value: Version) -> &mut Self[src]

pub fn version(&mut self, value: KeyVersion) -> &mut Self[src]

pub fn expiration(&mut self, value: Option<Duration>) -> &mut Self[src]

pub fn subkeys(&mut self, value: Vec<SubkeyParams>) -> &mut Self[src]

pub fn build(&self) -> Result<SecretKeyParams, String>[src]

Builds a new SecretKeyParams.

Errors

If a required field has not been initialized.

impl SecretKeyParamsBuilder[src]

pub fn user_id<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self[src]

pub fn subkey<VALUE: Into<SubkeyParams>>(&mut self, value: VALUE) -> &mut Self[src]

Trait Implementations

impl Clone for SecretKeyParamsBuilder[src]

impl Default for SecretKeyParamsBuilder[src]

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Clear for T where
    T: InitializableFromZeroed + ?Sized
[src]

impl<T> InitializableFromZeroed for T where
    T: Default
[src]

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Err = <U as TryFrom<T>>::Err