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:
Iterable<Map.Entry<String,String>>
Enclosing class:
DefaultHttpChunkTrailer

private static final class DefaultHttpChunkTrailer.TrailingHeaders extends DefaultHttpHeaders
  • Constructor Details

    • TrailingHeaders

      TrailingHeaders(boolean validateHeaders)
  • Method Details

    • add

      public HttpHeaders add(String name, Object value)
      Description copied from class: HttpHeaders
      Adds a new header with the specified name and value. If the specified value is not a String, it is converted into a String by Object.toString(), except in the cases of Date and Calendar, which are formatted to the date format defined in RFC2616.
      Overrides:
      add in class DefaultHttpHeaders
      Parameters:
      name - The name of the header being added
      value - The value of the header being added
      Returns:
      this
    • add

      public HttpHeaders add(String name, 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 class DefaultHttpHeaders
      Parameters:
      name - The name of the headers being set
      values - The values of the headers being set
      Returns:
      this
    • set

      public HttpHeaders set(String name, 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 class DefaultHttpHeaders
      Parameters:
      name - The name of the headers being set
      values - The values of the headers being set
      Returns:
      this
    • set

      public HttpHeaders set(String name, 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 a String, it is converted into a String by Object.toString(), except for Date and Calendar, which are formatted to the date format defined in RFC2616.
      Overrides:
      set in class DefaultHttpHeaders
      Parameters:
      name - The name of the header being set
      value - The value of the header being set
      Returns:
      this
    • validateName

      private static void validateName(String name)