ankh v0.1.1 Ankh.Stream

HTTP/2 Stream strucure

Summary

Types

Stream states

t()
  • id: stream id
  • state: stream state
  • hbf_type: type of HBF being accumulated
  • hbf: HBF accumulator, for reassembly
  • data: DATA accumulator, for reassembly
  • window_size: stream window size

Functions

Creates a new Stream

Process the reception of a frame through the Stream state machine

Process sending a frame through the Stream state machine

Types

error()
error :: {:error, :stream_closed | :protocol_error}
stream_state()
stream_state ::
  :idle |
  :open |
  :closed |
  :half_closed_local |
  :half_closed_remote |
  :reserved_remote |
  :reserved_local

Stream states

t()
t :: %Ankh.Stream{data: binary, hbf: binary, hbf_type: :headers | :push_promise, id: Integer.t, state: stream_state, window_size: Integer.t}
  • id: stream id
  • state: stream state
  • hbf_type: type of HBF being accumulated
  • hbf: HBF accumulator, for reassembly
  • data: DATA accumulator, for reassembly
  • window_size: stream window size

Functions

new(id, state)

Creates a new Stream

Parameters:

  • id: stream id
  • state: stream state
received_frame(stream, arg2)
received_frame(t, Ankh.Frame.t) :: {:ok, t} | error

Process the reception of a frame through the Stream state machine

send_frame(stream, arg2)
send_frame(t, Ankh.Frame.t) :: {:ok, t} | error

Process sending a frame through the Stream state machine