Skip to main content

Accepting

Trait Accepting 

Source
pub trait Accepting {
    type Error: Error + Send + Sync + 'static;

    // Required methods
    fn listing(&mut self, offer: &Offer) -> Result<Option<String>, Self::Error>;
    fn take<R: CryptoRng>(
        &mut self,
        offer: &Offer,
        grant: &InvitationGrant,
        rng: &mut R,
    ) -> Result<(), Self::Error>;
}
Expand description

The joiner’s side of an invitation: its listing for what the admin offers, and how it takes the space.

Required Associated Types§

Source

type Error: Error + Send + Sync + 'static

Why signing the listing or taking the space failed.

Required Methods§

Source

fn listing(&mut self, offer: &Offer) -> Result<Option<String>, Self::Error>

The joiner’s listing in the space that offer names, signed by its key, as text; None if its library holds the space already.

§Errors

Returns an error if the library cannot be read.

Source

fn take<R: CryptoRng>( &mut self, offer: &Offer, grant: &InvitationGrant, rng: &mut R, ) -> Result<(), Self::Error>

Takes the space that grant gives, as offer named it.

§Errors

Returns an error if the first key does not open, or the space cannot be made.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§