Class CompressedHeadersBuilder
java.lang.Object
org.glassfish.grizzly.http2.frames.CompressedHeadersBuilder
The builder for compressed headers used by
HeadersFrame.- Author:
- Alexey Stashok
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbuild(HeadersEncoder encoder) contentLength(long contentLength) Set the content-length of this header.contentType(String contentType) Set the content-type of this header.Add the HTTP mime header.Add the HTTP mime header.Set the the host/port (See RFC1738 [RFC1738]) portion of the URL for this request header (e.g.Set the the HTTP method for this request.Set the the HTTP method for this request.static CompressedHeadersBuilderReturns theCompressedHeadersBuilderinstance.Set the url-path for required url with "/" prefixed.Set the scheme portion of the URL for this request header (e.g.status(int status) Set the HTTP response status code (e.g.Set the HTTP response status code (e.g.status(HttpStatus status) Set the HTTP response status code (e.g.Set the the HTTP version of this request (e.g.Set the the HTTP version of this request (e.g.
-
Method Details
-
newInstance
Returns theCompressedHeadersBuilderinstance. -
contentLength
Set the content-length of this header. Applicable only in case of fixed-length HTTP message.- Parameters:
contentLength- the content-length of thisHttpPacket. Applicable only in case of fixed-length HTTP message.
-
contentType
Set the content-type of this header.- Parameters:
contentType- the content-type of thisHttpPacket.
-
method
Set the the HTTP method for this request. (e.g. "GET", "POST", "HEAD", etc).- Parameters:
method- the method of this header.
-
method
Set the the HTTP method for this request. (e.g. "GET", "POST", "HEAD", etc).- Parameters:
method- the method of this header.
-
path
Set the url-path for required url with "/" prefixed. (See RFC1738 [RFC1738]). For example, for "http://www.google.com/search?q=dogs" the path would be "/search?q=dogs".- Parameters:
path- the path of this header.
-
version
Set the the HTTP version of this request (e.g. "HTTP/1.1").- Parameters:
version- the HTTP version of this header.
-
version
Set the the HTTP version of this request (e.g. "HTTP/1.1").- Parameters:
version- the HTTP version of this header.
-
host
Set the the host/port (See RFC1738 [RFC1738]) portion of the URL for this request header (e.g. "www.google.com:1234"). This header is the same as the HTTP 'Host' header.- Parameters:
host- the host/port.
-
scheme
Set the scheme portion of the URL for this request header (e.g. "https").- Parameters:
scheme- the scheme of this header.
-
status
Set the HTTP response status code (e.g. 200 or 404).- Parameters:
status- the status of this header.
-
status
Set the HTTP response status code (e.g. "200" or "200 OK")- Parameters:
status- the status of this header.
-
status
Set the HTTP response status code (e.g. "200" or "200 OK")- Parameters:
status- the status of this header.
-
header
Add the HTTP mime header.- Parameters:
name- the mime header name.value- the mime header value.
-
header
Add the HTTP mime header.- Parameters:
header- the mimeHeader.value- the mime header value.
-
build
- Throws:
IOException
-