Trait sc_network::service::traits::NotificationSenderReady

source ·
pub trait NotificationSenderReady {
    // Required method
    fn send(
        &mut self,
        notification: Vec<u8>,
    ) -> Result<(), NotificationSenderError>;
}
Expand description

Reserved slot in the notifications buffer, ready to accept data.

Required Methods§

source

fn send(&mut self, notification: Vec<u8>) -> Result<(), NotificationSenderError>

Consumes this slots reservation and actually queues the notification.

NOTE: Traits can’t consume itself, but calling this method second time will return an error.

Implementors§