Skip to content

Latest commit

 

History

History
80 lines (40 loc) · 1.58 KB

bookish_spork_response.md

File metadata and controls

80 lines (40 loc) · 1.58 KB

Module bookish_spork_response

Data Types


response() = t() | non_neg_integer() | {non_neg_integer(), map(), binary()} | {non_neg_integer(), list(), binary()} | nonempty_list()

abstract datatype: t()

Function Index

new/1Constructs a response data structure.
write_str/2

Function Details

new/1


new(Response::response()) -> t()

Constructs a response data structure

Arg can be one of

Headers may be map or proplist

Example:

  bookish_spork_response:new([200, #{}, <<"Hello">>])

write_str/2


write_str(Response::t(), Now::calendar:datetime()) -> binary()