HeaderList.set

void set(string name, string value, string charset = null)

Set the value of the specified header. If value is null and the header, name, had not been previously set, a space will be set aside for it (useful for setting the order of headers before values can be obtained for them) otherwise the header will be unset.

Note

If there are multiple headers with the specified field name,

the first instance of the header will be replaced and further instances will be removed.

Parameters

nameheader name
valueheader value
charseta charset