pub struct EventStreamWriter {}Expand description
Emits AWS event-stream binary frames for a Select response. Each frame
is [total_len BE u32][headers_len BE u32][prelude CRC32][headers...][payload][message CRC32].
Header value type is fixed at 7 (UTF-8 string). Headers always
emitted: :event-type, :message-type, plus :content-type for
payload-bearing frames (Records / Stats).
Implementations§
Source§impl EventStreamWriter
impl EventStreamWriter
pub fn new() -> Self
Sourcepub fn records(&mut self, payload: &[u8]) -> Vec<u8> ⓘ
pub fn records(&mut self, payload: &[u8]) -> Vec<u8> ⓘ
Build a Records frame. payload is the (optionally empty) body
chunk — typically a CSV / JSON-Lines slab of one or more output
rows. AWS allows splitting a logical record across frames.
Trait Implementations§
Source§impl Debug for EventStreamWriter
impl Debug for EventStreamWriter
Source§impl Default for EventStreamWriter
impl Default for EventStreamWriter
Source§fn default() -> EventStreamWriter
fn default() -> EventStreamWriter
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for EventStreamWriter
impl RefUnwindSafe for EventStreamWriter
impl Send for EventStreamWriter
impl Sync for EventStreamWriter
impl Unpin for EventStreamWriter
impl UnsafeUnpin for EventStreamWriter
impl UnwindSafe for EventStreamWriter
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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