Class RequestHeaderMethodArgumentResolver

All Implemented Interfaces:
HandlerMethodArgumentResolver, SyncHandlerMethodArgumentResolver

public class RequestHeaderMethodArgumentResolver extends AbstractNamedValueSyncArgumentResolver
Resolves method arguments annotated with @RequestHeader except for Map arguments. See RequestHeaderMapMethodArgumentResolver for details on Map arguments annotated with @RequestHeader.

An @RequestHeader is a named value resolved from a request header. It has a required flag and a default value to fall back on when the request header does not exist.

A ConversionService is invoked to apply type conversion to resolved request header values that don't yet match the method parameter type.

Since:
5.0
Author:
Rossen Stoyanchev
See Also: