Skip to main content

Decrypt

Trait Decrypt 

Source
pub trait Decrypt: Sized {
    type Output;

    // Required method
    fn decrypt(
        self,
        recipient_x25519_pubkey: &[u8; 32],
        recipient_x25519_secret: &[u8; 32],
    ) -> Result<Self::Output, DecryptError>;

    // Provided method
    fn decrypt_with_keypair(
        self,
        recipient_keypair: &Keypair,
    ) -> Result<Self::Output, DecryptError>
       where Self: Sized { ... }
}

Required Associated Types§

Required Methods§

Source

fn decrypt( self, recipient_x25519_pubkey: &[u8; 32], recipient_x25519_secret: &[u8; 32], ) -> Result<Self::Output, DecryptError>

Provided Methods§

Source

fn decrypt_with_keypair( self, recipient_keypair: &Keypair, ) -> Result<Self::Output, DecryptError>
where Self: Sized,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§