pub struct ChannelInfo {
pub pv_name: String,
pub cid: u32,
pub sid: Option<u32>,
pub last_seen: Instant,
pub fully_established: bool,
pub update_times: VecDeque<Instant>,
pub recent_messages: VecDeque<String>,
}Expand description
Information about a channel (PV)
Fields§
§pv_name: StringPV name
cid: u32Client Channel ID
sid: Option<u32>Server Channel ID (assigned by server in CREATE_CHANNEL response)
last_seen: InstantWhen this channel was created/last accessed
fully_established: boolWhether we saw the full CREATE_CHANNEL exchange
update_times: VecDeque<Instant>§recent_messages: VecDeque<String>Implementations§
Source§impl ChannelInfo
impl ChannelInfo
pub fn new_pending(cid: u32, pv_name: String) -> Self
pub fn touch(&mut self)
pub fn is_expired(&self, ttl: Duration) -> bool
Trait Implementations§
Source§impl Clone for ChannelInfo
impl Clone for ChannelInfo
Source§fn clone(&self) -> ChannelInfo
fn clone(&self) -> ChannelInfo
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 ChannelInfo
impl RefUnwindSafe for ChannelInfo
impl Send for ChannelInfo
impl Sync for ChannelInfo
impl Unpin for ChannelInfo
impl UnsafeUnpin for ChannelInfo
impl UnwindSafe for ChannelInfo
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