pub trait Publisher {
// Required methods
fn publish<S: ToSubject>(
&self,
subject: S,
payload: Bytes,
) -> impl Future<Output = Result<PublishAckFuture, PublishError>>;
fn publish_message(
&self,
message: OutboundMessage,
) -> impl Future<Output = Result<PublishAckFuture, PublishError>>;
}
Required Methods§
fn publish<S: ToSubject>( &self, subject: S, payload: Bytes, ) -> impl Future<Output = Result<PublishAckFuture, PublishError>>
fn publish_message( &self, message: OutboundMessage, ) -> impl Future<Output = Result<PublishAckFuture, PublishError>>
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.