Class HeaderElement

java.lang.Object
org.apache.juneau.commons.http.HeaderElement

public class HeaderElement extends Object
Represents a parsed element from an HTTP header value.

An element consists of a name and zero or more parameters, as defined by RFC 2616. For example, in the header value "text/html;charset=UTF-8;q=0.9", the element name is "text/html" and the parameters are "charset=UTF-8" and "q=0.9".

  • Constructor Details

    • HeaderElement

      public HeaderElement(String name, NameValuePair... parameters)
      Constructor.
      Parameters:
      name - The element name.
      parameters - The element parameters.
  • Method Details

    • getName

      public String getName()
      Returns the element name.
      Returns:
      The element name, never null.
    • getParameters

      Returns the element parameters.
      Returns:
      The parameters array, never null.