HttpContext
Class
Http context stores arbitrary user defined values and ensures type safety without
actually knowing the types. It is backed by a Map
and guarantees that keys do not clash.
API
Description
Usage Notes
class HttpContext {}
set
Store a value in the context. If a value is already present it will be overwritten.
@paramvalue
T
The value to store.
@returns
HttpContext
get
T
Retrieve the value associated with the given token.
@returns
T
delete
Delete the value associated with the given token.
@returns
HttpContext
has
boolean
Checks for existence of a given token.
@returns
boolean
keys
IterableIterator<HttpContextToken<unknown>>
@returns
IterableIterator<HttpContextToken<unknown>>
Jump to details