View Source cowmachine_accept_language (cowmachine v1.12.1)
Link to this section Summary
Link to this section Functions
-spec accept_header(AvailableLangs, AcceptHeader) -> Result when AvailableLangs :: [{binary(), [binary()]}], AcceptHeader :: cowmachine_req:context() | binary() | undefined, Result :: {ok, binary()} | {error, nomatch | header}.
-spec accept_list(AvailableLangs, AcceptableLangs) -> Result
when
AvailableLangs :: [{binary(), [binary()]}],
AcceptableLangs :: [binary()],
Result :: {ok, binary()} | {error, nomatch}.
-spec parse_header(AcceptHeader) -> Result when AcceptHeader :: cowmachine_req:context() | binary() | undefined, Result :: {ok, [binary()]} | {error, nomatch | header}.