- All Known Implementing Classes:
HttpHeader,HttpRequestPacket,HttpResponsePacket,HttpTrailer
public interface MimeHeadersPacket
Common interface for
HttpPackets, which contain mimeheaders.- Author:
- Alexey Stashok
-
Method Summary
Modifier and TypeMethodDescriptionvoidAdd the HTTP mime header.voidaddHeader(String name, HeaderValue value) Add the HTTP mime header.voidAdd the HTTP mime header.voidaddHeader(Header header, HeaderValue value) Add the HTTP mime header.booleancontainsHeader(String name) Returns true, if the mime header with the specific name is present among the HttpHeader mime headers, or false otherwise.booleancontainsHeader(Header header) Returns true, if the mimeHeaderis present among the HttpHeader mime headers, otherwise returns false.Get the value, of the specific HTTP mime header.Get the value, of the specific HTTP mime header.Get allMimeHeaders, associated with the HttpHeader.voidSet the value, of the specific HTTP mime header.voidsetHeader(String name, HeaderValue value) Set the value, of the specific HTTP mime header.voidSet the value, of the specific HTTP mime header.voidsetHeader(Header header, HeaderValue value) Set the value, of the specific HTTP mime header.
-
Method Details
-
getHeaders
MimeHeaders getHeaders()Get allMimeHeaders, associated with the HttpHeader.- Returns:
- all
MimeHeaders, associated with the HttpHeader
-
getHeader
Get the value, of the specific HTTP mime header.- Parameters:
name- the mime header name- Returns:
- the value, of the specific HTTP mime header
-
getHeader
Get the value, of the specific HTTP mime header.- Parameters:
header- the mimeHeader- Returns:
- the value, of the specific HTTP mime header
- Since:
- 2.1.2
-
setHeader
Set the value, of the specific HTTP mime header.- Parameters:
name- the mime header namevalue- the mime header value
-
setHeader
Set the value, of the specific HTTP mime header.- Parameters:
name- the mime header namevalue- the mime header value- Since:
- 2.3.8
-
setHeader
Set the value, of the specific HTTP mime header.- Parameters:
header- the mimeHeadervalue- the mime header value- Since:
- 2.1.2
-
setHeader
Set the value, of the specific HTTP mime header.- Parameters:
header- the mimeHeadervalue- the mime header value- Since:
- 2.3.8
-
addHeader
Add the HTTP mime header.- Parameters:
name- the mime header namevalue- the mime header value
-
addHeader
Add the HTTP mime header.- Parameters:
name- the mime header namevalue- the mime header value- Since:
- 2.3.8
-
addHeader
Add the HTTP mime header.- Parameters:
header- the mimeHeadervalue- the mime header value- Since:
- 2.1.2
-
addHeader
Add the HTTP mime header.- Parameters:
header- the mimeHeadervalue- the mime header value- Since:
- 2.3.8
-
containsHeader
Returns true, if the mime header with the specific name is present among the HttpHeader mime headers, or false otherwise.- Parameters:
name- the mime header name- Returns:
- true, if the mime header with the specific name is present among the HttpHeader mime headers, or false otherwise
-
containsHeader
Returns true, if the mimeHeaderis present among the HttpHeader mime headers, otherwise returns false.
-