[][src]Struct zenoh_protocol::proto::Sync

pub struct Sync {
    pub ch: Channel,
    pub sn: ZInt,
    pub count: Option<ZInt>,
}

NOTE: 16 bits (2 bytes) may be prepended to the serialized message indicating the total lenght in bytes of the message, resulting in the maximum lenght of a message being 65_536 bytes. This is necessary in those stream-oriented transports (e.g., TCP) that do not preserve the boundary of the serialized messages. The length is encoded as little-endian. In any case, the lenght of a message must not exceed 65_535 bytes.

The SYNC message allows to signal the corresponding peer the sequence number of the next message to be transmitted on the reliable or best-effort channel. In the case of reliable channel, the peer can optionally include the number of unacknowledged messages. A SYNC sent on the reliable channel triggers the transmission of an ACKNACK message.

7 6 5 4 3 2 1 0 +-+-+-+-+-+-+-+-+ |X|C|R| SYNC | +-+-+-+-+-------+ ~ sn ~ -- Sequence number of the next message to be transmitted on this channel. +---------------+ ~ count ~ if R==1 && C==1 -- Number of unacknowledged messages. +---------------+

  • if R==1 then the SYNC concerns the reliable channel, otherwise the best-effort channel.

Fields

ch: Channelsn: ZIntcount: Option<ZInt>

Trait Implementations

impl Clone for Sync[src]

impl Debug for Sync[src]

impl PartialEq<Sync> for Sync[src]

impl StructuralPartialEq for Sync[src]

Auto Trait Implementations

impl RefUnwindSafe for Sync

impl Send for Sync

impl Sync for Sync

impl Unpin for Sync

impl UnwindSafe for Sync

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,