Class DefaultHttpChunkTrailer.TrailingHeaders
- java.lang.Object
-
- org.jboss.netty.handler.codec.http.HttpHeaders
-
- org.jboss.netty.handler.codec.http.DefaultHttpHeaders
-
- org.jboss.netty.handler.codec.http.DefaultHttpChunkTrailer.TrailingHeaders
-
- All Implemented Interfaces:
java.lang.Iterable<java.util.Map.Entry<java.lang.String,java.lang.String>>
- Enclosing class:
- DefaultHttpChunkTrailer
private static final class DefaultHttpChunkTrailer.TrailingHeaders extends DefaultHttpHeaders
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.jboss.netty.handler.codec.http.HttpHeaders
HttpHeaders.Names, HttpHeaders.Values
-
-
Field Summary
-
Fields inherited from class org.jboss.netty.handler.codec.http.DefaultHttpHeaders
validate
-
Fields inherited from class org.jboss.netty.handler.codec.http.HttpHeaders
EMPTY_HEADERS
-
-
Constructor Summary
Constructors Constructor Description TrailingHeaders(boolean validateHeaders)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description HttpHeaders
add(java.lang.String name, java.lang.Iterable<?> values)
Adds a new header with the specified name and values.HttpHeaders
add(java.lang.String name, java.lang.Object value)
Adds a new header with the specified name and value.HttpHeaders
set(java.lang.String name, java.lang.Iterable<?> values)
Sets a header with the specified name and values.HttpHeaders
set(java.lang.String name, java.lang.Object value)
Sets a header with the specified name and value.private static void
validateName(java.lang.String name)
-
Methods inherited from class org.jboss.netty.handler.codec.http.DefaultHttpHeaders
clear, contains, contains, entries, get, getAll, isEmpty, iterator, names, remove, validateHeaderValue0
-
Methods inherited from class org.jboss.netty.handler.codec.http.HttpHeaders
add, addDateHeader, addHeader, addIntHeader, clearHeaders, getContentLength, getContentLength, getDate, getDate, getDateHeader, getDateHeader, getHeader, getHeader, getHost, getHost, getIntHeader, getIntHeader, is100ContinueExpected, isContentLengthSet, isKeepAlive, isTransferEncodingChunked, removeHeader, removeTransferEncodingChunked, set, set100ContinueExpected, set100ContinueExpected, setContentLength, setDate, setDateHeader, setDateHeader, setHeader, setHeader, setHost, setIntHeader, setIntHeader, setKeepAlive, setTransferEncodingChunked, validateHeaderName, validateHeaderValue, valideHeaderNameChar
-
-
-
-
Method Detail
-
add
public HttpHeaders add(java.lang.String name, java.lang.Object value)
Description copied from class:HttpHeaders
Adds a new header with the specified name and value. If the specified value is not aString
, it is converted into aString
byObject.toString()
, except in the cases ofDate
andCalendar
, which are formatted to the date format defined in RFC2616.- Overrides:
add
in classDefaultHttpHeaders
- Parameters:
name
- The name of the header being addedvalue
- The value of the header being added- Returns:
this
-
add
public HttpHeaders add(java.lang.String name, java.lang.Iterable<?> values)
Description copied from class:HttpHeaders
Adds a new header with the specified name and values. This getMethod can be represented approximately as the following code:for (Object v: values) { if (v == null) { break; } headers.add(name, v); }
- Overrides:
add
in classDefaultHttpHeaders
- Parameters:
name
- The name of the headers being setvalues
- The values of the headers being set- Returns:
this
-
set
public HttpHeaders set(java.lang.String name, java.lang.Iterable<?> values)
Description copied from class:HttpHeaders
Sets a header with the specified name and values. If there is an existing header with the same name, it is removed. This getMethod can be represented approximately as the following code:headers.remove(name); for (Object v: values) { if (v == null) { break; } headers.add(name, v); }
- Overrides:
set
in classDefaultHttpHeaders
- Parameters:
name
- The name of the headers being setvalues
- The values of the headers being set- Returns:
this
-
set
public HttpHeaders set(java.lang.String name, java.lang.Object value)
Description copied from class:HttpHeaders
Sets a header with the specified name and value. If there is an existing header with the same name, it is removed. If the specified value is not aString
, it is converted into aString
byObject.toString()
, except forDate
andCalendar
, which are formatted to the date format defined in RFC2616.- Overrides:
set
in classDefaultHttpHeaders
- Parameters:
name
- The name of the header being setvalue
- The value of the header being set- Returns:
this
-
validateName
private static void validateName(java.lang.String name)
-
-