Package org.apache.hc.core5.http
Interface HeaderElement
- All Known Implementing Classes:
BasicHeaderElement
public interface HeaderElement
Represents an element of an HTTP
header
value consisting of
a name / value pair and a number of optional name / value parameters.- Since:
- 4.0
-
Method Summary
Modifier and TypeMethodDescriptiongetName()
Returns header element name.getParameter
(int index) Returns parameter with the given index.getParameterByName
(String name) Returns the first parameter with the given name.int
Returns the total count of parameters.Returns an array of name / value pairs.getValue()
Returns header element value.
-
Method Details
-
getName
String getName()Returns header element name.- Returns:
- header element name
-
getValue
String getValue()Returns header element value.- Returns:
- header element value
-
getParameters
NameValuePair[] getParameters()Returns an array of name / value pairs.- Returns:
- array of name / value pairs
-
getParameterByName
Returns the first parameter with the given name.- Parameters:
name
- parameter name- Returns:
- name / value pair
-
getParameterCount
int getParameterCount()Returns the total count of parameters.- Returns:
- parameter count
-
getParameter
Returns parameter with the given index.- Parameters:
index
- index- Returns:
- name / value pair
-