Tinkex.Streaming.SSEDecoder (Tinkex v0.3.4)
View SourceMinimal SSE decoder that can be fed incremental chunks.
Summary
Functions
Feed a binary chunk into the decoder, returning parsed events and updated state.
Create a new decoder.
Types
@type t() :: %Tinkex.Streaming.SSEDecoder{buffer: binary()}
Functions
@spec feed(t(), binary()) :: {[Tinkex.Streaming.ServerSentEvent.t()], t()}
Feed a binary chunk into the decoder, returning parsed events and updated state.
@spec new() :: t()
Create a new decoder.