pub struct RtrEndOfData {
pub version: RtrProtocolVersion,
pub session_id: u16,
pub serial_number: u32,
pub refresh_interval: Option<u32>,
pub retry_interval: Option<u32>,
pub expire_interval: Option<u32>,
}Expand description
End of Data PDU (Type 7)
Sent by server to indicate the end of a data transfer.
Direction: Server → Client
Note: In v1, this PDU includes timing parameters. In v0, these are absent.
Fields§
§version: RtrProtocolVersionProtocol version
session_id: u16Session identifier
serial_number: u32Current serial number
refresh_interval: Option<u32>Refresh interval in seconds (v1 only)
retry_interval: Option<u32>Retry interval in seconds (v1 only)
expire_interval: Option<u32>Expire interval in seconds (v1 only)
Implementations§
Source§impl RtrEndOfData
impl RtrEndOfData
Sourcepub const DEFAULT_REFRESH: u32 = 3_600u32
pub const DEFAULT_REFRESH: u32 = 3_600u32
Default refresh interval (1 hour) as recommended by RFC 8210
Sourcepub const DEFAULT_RETRY: u32 = 600u32
pub const DEFAULT_RETRY: u32 = 600u32
Default retry interval (10 minutes) as recommended by RFC 8210
Sourcepub const DEFAULT_EXPIRE: u32 = 7_200u32
pub const DEFAULT_EXPIRE: u32 = 7_200u32
Default expire interval (2 hours) as recommended by RFC 8210
Sourcepub fn refresh_interval_or_default(&self) -> u32
pub fn refresh_interval_or_default(&self) -> u32
Get the refresh interval, using the default if not specified
Sourcepub fn retry_interval_or_default(&self) -> u32
pub fn retry_interval_or_default(&self) -> u32
Get the retry interval, using the default if not specified
Sourcepub fn expire_interval_or_default(&self) -> u32
pub fn expire_interval_or_default(&self) -> u32
Get the expire interval, using the default if not specified
Trait Implementations§
Source§impl Clone for RtrEndOfData
impl Clone for RtrEndOfData
Source§fn clone(&self) -> RtrEndOfData
fn clone(&self) -> RtrEndOfData
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 moreSource§impl Debug for RtrEndOfData
impl Debug for RtrEndOfData
Source§impl From<RtrEndOfData> for RtrPdu
impl From<RtrEndOfData> for RtrPdu
Source§fn from(pdu: RtrEndOfData) -> Self
fn from(pdu: RtrEndOfData) -> Self
Converts to this type from the input type.
Source§impl Hash for RtrEndOfData
impl Hash for RtrEndOfData
Source§impl PartialEq for RtrEndOfData
impl PartialEq for RtrEndOfData
Source§impl RtrEncode for RtrEndOfData
impl RtrEncode for RtrEndOfData
impl Eq for RtrEndOfData
impl StructuralPartialEq for RtrEndOfData
Auto Trait Implementations§
impl Freeze for RtrEndOfData
impl RefUnwindSafe for RtrEndOfData
impl Send for RtrEndOfData
impl Sync for RtrEndOfData
impl Unpin for RtrEndOfData
impl UnwindSafe for RtrEndOfData
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more