public class StaticHeadersWriter extends Object implements HeaderWriter
HeaderWriter
implementation which writes the same Header
instance.Constructor and Description |
---|
StaticHeadersWriter(List<Header> headers)
Creates a new instance
|
StaticHeadersWriter(String headerName,
String... headerValues)
Creates a new instance with a single header
|
Modifier and Type | Method and Description |
---|---|
String |
toString() |
void |
writeHeaders(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Create a
Header instance. |
public StaticHeadersWriter(List<Header> headers)
headers
- the Header
instances to usepublic void writeHeaders(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
HeaderWriter
Header
instance.writeHeaders
in interface HeaderWriter
request
- the requestresponse
- the response