ic-bn-lib-common 0.1.8

A collection of traits & types commonly used by ic-bn-lib and others
Documentation
1
2
3
4
5
6
7
8
9
use std::hash::Hash;

/// Trait that a topic ID should implement
pub trait TopicId: Hash + Eq + Clone + Send + Sync + 'static {}
impl<T: Hash + Eq + Clone + Send + Sync + 'static> TopicId for T {}

/// Trait that a message should implement
pub trait Message: Clone + Send + Sync + 'static {}
impl<T: Clone + Send + Sync + 'static> Message for T {}