javax.ws.rs
Annotation Type HeaderParam


@Target(value=PARAMETER)
@Retention(value=RUNTIME)
@Documented
public @interface HeaderParam

Binds a HTTP header to a Java method parameter. Where multiple headers of the same name exist in a request, the first value is used - see HttpHeaders for a means of retrieving all values of particular header. A default value can be specified using the DefaultValue annotation. The type of the annotated parameter must either:

See Also:
DefaultValue, HttpHeaders

Required Element Summary
 java.lang.String value
          Defines the name of the HTTP header whose value will be used to initialize the value of the annotated method argument, class field or bean property.
 

Element Detail

value

public abstract java.lang.String value
Defines the name of the HTTP header whose value will be used to initialize the value of the annotated method argument, class field or bean property. Case insensitive.