[][src]Struct nakadion::components::streams::NakadiFrame

pub struct NakadiFrame {
    pub bytes: Bytes,
    pub started_at: Instant,
    pub completed_at: Instant,
    pub frame_id: usize,
}

A frame (line) from Nakadi

Fields

bytes: Bytesstarted_at: Instant

Timestamp when the first byte was received

completed_at: Instant

Timestamp when the frame was completed

frame_id: usize

Implementations

impl NakadiFrame[src]

pub fn new(
    bytes: Vec<u8>,
    started_at: Instant,
    completed_at: Instant,
    frame_id: usize
) -> Self
[src]

pub fn as_bytes(&self) -> &[u8]

Notable traits for &'_ [u8]

impl<'_> Read for &'_ [u8]impl<'_> Write for &'_ mut [u8]
[src]

Trait Implementations

impl AsRef<[u8]> for NakadiFrame[src]

impl Clone for NakadiFrame[src]

impl Debug for NakadiFrame[src]

Auto Trait Implementations

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> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized

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>,