penumbra_proto::state

Trait StateWriteProto

Source
pub trait StateWriteProto:
    StateWrite
    + Send
    + Sync {
    // Provided methods
    fn put<D>(&mut self, key: String, value: D)
       where D: DomainType,
             Error: From<<D as TryFrom<D::Proto>>::Error> { ... }
    fn put_proto<P>(&mut self, key: String, value: P)
       where P: Message + Default + Debug { ... }
    fn nonverifiable_put<D>(&mut self, key: Vec<u8>, value: D)
       where D: DomainType,
             Error: From<<D as TryFrom<D::Proto>>::Error> { ... }
    fn nonverifiable_put_proto<P>(&mut self, key: Vec<u8>, value: P)
       where P: Message + Default + Debug { ... }
    fn record_proto<E>(&mut self, proto_event: E)
       where E: ProtoEvent { ... }
}
Available on crate feature cnidarium only.

Provided Methods§

Source

fn put<D>(&mut self, key: String, value: D)
where D: DomainType, Error: From<<D as TryFrom<D::Proto>>::Error>,

Puts a domain type into the verifiable key-value store with the given key.

Source

fn put_proto<P>(&mut self, key: String, value: P)
where P: Message + Default + Debug,

Puts a proto type into the verifiable key-value store with the given key.

Source

fn nonverifiable_put<D>(&mut self, key: Vec<u8>, value: D)
where D: DomainType, Error: From<<D as TryFrom<D::Proto>>::Error>,

Puts a domain type into the nonverifiable key-value store with the given key

Source

fn nonverifiable_put_proto<P>(&mut self, key: Vec<u8>, value: P)
where P: Message + Default + Debug,

Puts a proto type into the verifiable key-value store with the given key.

Source

fn record_proto<E>(&mut self, proto_event: E)
where E: ProtoEvent,

Records a Protobuf message as a typed ABCI event.

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§