http_type/any/impl.rs
1use crate::*;
2
3/// Implements `AnySend` for types that are `Any` and `Send`.
4///
5/// This trait signifies that a type can be safely sent across thread boundaries.
6impl<T: Any + Send> AnySend for T {}
7
8/// Implements `AnySendClone` for types that are `Any`, `Send`, and `Clone`.
9///
10/// This trait signifies that a type can be safely sent across thread boundaries and cloned.
11impl<T: Any + Send + Clone> AnySendClone for T {}
12
13/// Implements `AnySync` for types that are `Any` and `Sync`.
14///
15/// This trait signifies that a type can be safely accessed from multiple threads concurrently.
16impl<T: Any + Sync> AnySync for T {}
17
18/// Implements `AnySyncClone` for types that are `Any`, `Sync`, and `Clone`.
19///
20/// This trait signifies that a type can be safely accessed concurrently and cloned.
21impl<T: Any + Sync + Clone> AnySyncClone for T {}
22
23/// Implements `AnySendSync` for types that are `Any`, `Send`, and `Sync`.
24///
25/// This trait signifies that a type can be safely sent across thread boundaries and accessed concurrently.
26impl<T: Any + Send + Sync> AnySendSync for T {}
27
28/// Implements `AnySendSyncClone` for types that are `Any`, `Send`, `Sync`, and `Clone`.
29///
30/// This trait signifies that a type can be safely sent across thread boundaries, accessed concurrently, and cloned.
31impl<T: Any + Send + Sync + Clone> AnySendSyncClone for T {}