Marmos
v juptune
v asn1
v lang
v ast
v Classes
v Enums
v ir
v parser
v Enums
v Structs
v core
v crypto
v keyexchange
v memory
v data
v alphabet
v buffer
v json
v builder
v parser
v Enums
v Structs
v serialise
v Structs
v Templates
v pem
v Enums
v Structs

Aliases HttpClient.StreamResponseFunc

1
2
3
4
5
6
module juptune.http.client;

alias StreamResponseFunc = Result function(
    HttpResponse statusAndHeaders, 
    const const ubyte[] bodyChunk
);

Documentation

A function provided by HttpClientwhich can be used to stream read data from the response body.

Please note that the HttpResponsedoes not contain a body - it only contains the headers and status line.

Please note that this is marked @safeto help make it clear that the scopefor bodyChunkis very important to adhear to.

You can (and probably will have to) mark your func/lambda as @trusted, but that will also disable the compiler making sure that you don't accidentally escape the bodyChunkparameter.

ON THIS PAGE