Class Headers
java.lang.Object
com.ibm.security.access.httpclient.Headers
This class stores the headers for a HTTP request.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Add a headerboolean
Add a headerString[]
Get the header values with the specified name.String[]
Get all the header names.Get all the headersboolean
removeHeader
(String name) Remove a header
-
Field Details
-
Headers_java_sourceCodeID
- See Also:
-
Headers_java_copyright
- See Also:
-
-
Constructor Details
-
Headers
public Headers()
-
-
Method Details
-
addHeader
Add a header- Parameters:
name
- Header namevalues
- A List(String) of header values- Returns:
- True if successful. False otherwise.
-
addHeader
Add a header- Parameters:
name
- Header namevalue
- Header value- Returns:
- True if successful. False otherwise.
-
getHeaderNames
Get all the header names. Returns null if there are no headers.- Returns:
- Header names. Null if no headers.
-
getHeaders
Get all the headers- Returns:
- A Map(String,List(String)) of all headers
-
getHeader
Get the header values with the specified name. Returns null if no such header name or name was null/empty string.- Parameters:
name
- The header name- Returns:
- A List(String) of values associated with that header name. Null if no such header name exists or name was null/empty string.
-
removeHeader
Remove a header- Parameters:
name
- Header name- Returns:
- True if successful. False otherwise.
-