Skip to content

ResponseBuilderBody

[Source]

interface ref ResponseBuilderBody

Public Functions

add_chunk

[Source]

Add some body data.

If Transfer-Encoding is set to Chunked in ResponseBuilderHeaders each call to this function will take care of encoding every added array here in Chunked encoding. Add an empty array to add the finishing chunk..

fun ref add_chunk(
  data: (String val | Array[U8 val] val))
: ResponseBuilderBody ref

Parameters

Returns


build

[Source]

Serialize the accumulated response data into a ByteSeqIter.

fun ref build()
: ByteSeqIter val

Returns


reset

[Source]

Reset the builder to a fresh state, only use the returned builder for further actions.

fun ref reset()
: ResponseBuilder ref

Returns