Struct SimpleSubscriptionManager
pub struct SimpleSubscriptionManager {}Expand description
Simple subscription manager implementation
Implementations§
§impl SimpleSubscriptionManager
impl SimpleSubscriptionManager
pub fn new() -> SimpleSubscriptionManager
pub fn new() -> SimpleSubscriptionManager
Create a new simple subscription manager
Trait Implementations§
§impl Debug for SimpleSubscriptionManager
impl Debug for SimpleSubscriptionManager
§impl SubscriptionManager for SimpleSubscriptionManager
impl SubscriptionManager for SimpleSubscriptionManager
§fn add_subscription(
&mut self,
_pattern: TopicPattern,
_handler: Arc<dyn MessageHandler>,
) -> Result<(), NerveError>
fn add_subscription( &mut self, _pattern: TopicPattern, _handler: Arc<dyn MessageHandler>, ) -> Result<(), NerveError>
Add a subscription
§fn remove_subscription(
&mut self,
_pattern: &TopicPattern,
) -> Result<(), NerveError>
fn remove_subscription( &mut self, _pattern: &TopicPattern, ) -> Result<(), NerveError>
Remove a subscription
§fn get_handlers(&self, _topic: &str) -> Vec<Arc<dyn MessageHandler>>
fn get_handlers(&self, _topic: &str) -> Vec<Arc<dyn MessageHandler>>
Get handlers for a topic
§fn subscription_count(&self) -> usize
fn subscription_count(&self) -> usize
Get subscription count
§fn clear_subscriptions(&mut self) -> Result<(), NerveError>
fn clear_subscriptions(&mut self) -> Result<(), NerveError>
Clear all subscriptions
Auto Trait Implementations§
impl Freeze for SimpleSubscriptionManager
impl RefUnwindSafe for SimpleSubscriptionManager
impl Send for SimpleSubscriptionManager
impl Sync for SimpleSubscriptionManager
impl Unpin for SimpleSubscriptionManager
impl UnwindSafe for SimpleSubscriptionManager
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