org.jboss.seam.servlet.http
Class HeaderParamProducer

java.lang.Object
  extended by org.jboss.seam.servlet.http.HeaderParamProducer

public class HeaderParamProducer
extends Object

A producer for a String bean qualified @HeaderParam.

Provides a producer method that retrieves the value of the specified HTTP header from HttpServletRequest.getHeader(String) and makes it available as a dependent-scoped bean of type String qualified @HeaderParam. The name of the HTTP header to lookup is either the value of the @HeaderParam annotation or, if the annotation value is empty, the name of the injection point (e.g., the field name).

If the HTTP header is not present, and the injection point is annotated with @DefaultValue, the value of the @DefaultValue annotation is returned instead. If @DefaultValue is not present, null is returned.

Author:
Dan Allen
See Also:
HeaderParam, DefaultValue

Constructor Summary
HeaderParamProducer()
           
 
Method Summary
protected  Object getTypedParamValue(InjectionPoint ip, ServletExtension ext)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HeaderParamProducer

public HeaderParamProducer()
Method Detail

getTypedParamValue

@Produces
@TypedParamValue
protected Object getTypedParamValue(InjectionPoint ip,
                                                             ServletExtension ext)


Copyright © 2011 Seam Framework. All Rights Reserved.