pub enum QueueStatus<T> {
Ok(Vec<T>),
Block(Vec<T>),
Disconnected(Vec<T>),
}
Expand description
Return type from methods used to send or receive messages/packets/commands.
This type is associated with methods that communicates with:
- Message-Queue, communication between shards
- Packet-Queue, communication between shard and socket
- Command-Queue, communication with thread.
Variants§
Implementations§
Source§impl<T> QueueStatus<T>
impl<T> QueueStatus<T>
pub fn take_values(&mut self) -> Vec<T>
pub fn set_values(&mut self, values: Vec<T>)
pub fn replace<U>(self, values: Vec<U>) -> QueueStatus<U>
pub fn map<F, U>(self, callb: F) -> QueueStatus<U>where
F: Fn(T) -> U,
pub fn is_disconnected(&self) -> bool
Trait Implementations§
Source§impl<T: Clone> Clone for QueueStatus<T>
impl<T: Clone> Clone for QueueStatus<T>
Source§fn clone(&self) -> QueueStatus<T>
fn clone(&self) -> QueueStatus<T>
Returns a copy 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<T> Freeze for QueueStatus<T>
impl<T> RefUnwindSafe for QueueStatus<T>where
T: RefUnwindSafe,
impl<T> Send for QueueStatus<T>where
T: Send,
impl<T> Sync for QueueStatus<T>where
T: Sync,
impl<T> Unpin for QueueStatus<T>where
T: Unpin,
impl<T> UnwindSafe for QueueStatus<T>where
T: UnwindSafe,
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