pub struct MessageBusOptions {
pub name: String,
pub topics: Vec<String>,
pub topic_policy: MessageBusTopicPolicy,
pub retention: MessageBusRetentionPolicy,
pub dedupe: MessageBusDedupePolicy,
pub now: Rc<dyn Fn() -> u64>,
}Expand description
MessageBusOptions data container.
Fields§
§name: Stringname field for name.
topics: Vec<String>topics field for topics.
topic_policy: MessageBusTopicPolicytopic_policy field for topic policy.
retention: MessageBusRetentionPolicyretention field for retention.
dedupe: MessageBusDedupePolicydedupe field for dedupe.
now: Rc<dyn Fn() -> u64>now field for now.
Implementations§
Source§impl MessageBusOptions
impl MessageBusOptions
Sourcepub fn with_topics(
self,
topics: impl IntoIterator<Item = impl Into<String>>,
) -> Self
pub fn with_topics( self, topics: impl IntoIterator<Item = impl Into<String>>, ) -> Self
Updates or reads with_topics.
Sourcepub fn with_topic_policy(self, policy: MessageBusTopicPolicy) -> Self
pub fn with_topic_policy(self, policy: MessageBusTopicPolicy) -> Self
Updates or reads with_topic_policy.
Sourcepub fn with_retention(self, retention: MessageBusRetentionPolicy) -> Self
pub fn with_retention(self, retention: MessageBusRetentionPolicy) -> Self
Updates or reads with_retention.
Sourcepub fn with_dedupe(self, dedupe: MessageBusDedupePolicy) -> Self
pub fn with_dedupe(self, dedupe: MessageBusDedupePolicy) -> Self
Updates or reads with_dedupe.
Trait Implementations§
Source§impl Clone for MessageBusOptions
impl Clone for MessageBusOptions
Source§fn clone(&self) -> MessageBusOptions
fn clone(&self) -> MessageBusOptions
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for MessageBusOptions
impl !RefUnwindSafe for MessageBusOptions
impl !Send for MessageBusOptions
impl !Sync for MessageBusOptions
impl Unpin for MessageBusOptions
impl UnsafeUnpin for MessageBusOptions
impl !UnwindSafe for MessageBusOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more