Package org.omegazero.proxy.http
Class ProxyHTTPRequest
java.lang.Object
org.omegazero.common.util.SimpleAttachmentContainer
org.omegazero.http.common.HTTPHeaderContainer
org.omegazero.http.common.HTTPMessage
org.omegazero.http.common.HTTPRequest
org.omegazero.proxy.http.ProxyHTTPRequest
- All Implemented Interfaces:
Serializable,org.omegazero.common.util.AttachmentContainer
public class ProxyHTTPRequest
extends org.omegazero.http.common.HTTPRequest
A
HTTPRequest that stores the initial request line values and contains additional proxy-specific methods.
The getInitial* methods in this class are not affected by their corresponding set* methods.
- Since:
- 3.6.1
- See Also:
-
Field Summary
Fields inherited from class org.omegazero.http.common.HTTPRequest
authority, httpResponder, method, path, schemeFields inherited from class org.omegazero.http.common.HTTPMessage
chunkedTransfer, createdTime, httpVersion, locked, otherFields inherited from class org.omegazero.http.common.HTTPHeaderContainer
headerFieldsFields inherited from class org.omegazero.common.util.SimpleAttachmentContainer
attachments -
Constructor Summary
ConstructorsConstructorDescriptionProxyHTTPRequest(String method, String scheme, String authority, String path, String version, org.omegazero.http.common.HTTPHeaderContainer headers) SeeHTTPRequest(String, String, String, String, String, HTTPHeaderContainer).ProxyHTTPRequest(ProxyHTTPRequest request) SeeHTTPRequest(HTTPRequest). -
Method Summary
Modifier and TypeMethodDescriptionReturns the initial HTTP request authority.Returns the initial HTTP version.Returns the initial HTTP request method.Returns the initial HTTP request path.Returns the initial HTTP request scheme.Returns the request ID of thisProxyHTTPRequest.voidrespondError(int status, String message, String... headers) Responds to thisHTTPRequestwith an error message.voidrespondError(int status, String title, String message, String... headers) Responds to thisHTTPRequestwith an error message.Methods inherited from class org.omegazero.http.common.HTTPRequest
getAuthority, getHttpResponder, getMethod, getOther, getPath, getScheme, hasResponse, requestLine, requestURI, respond, respond, setAuthority, setHttpResponder, setMethod, setPath, setSchemeMethods inherited from class org.omegazero.http.common.HTTPMessage
checkLocked, getCreatedTime, getHttpVersion, isChunkedTransfer, isLocked, lock, setChunkedTransfer, setHttpVersion, setOtherMethods inherited from class org.omegazero.http.common.HTTPHeaderContainer
addHeader, addHeader, appendHeader, appendHeader, appendHeader, deleteHeader, deleteHeader, editHeader, extractHeader, extractHeaders, fromLegacy, getHeader, getHeader, getHeader, getHeader, getHeaderCount, headerExists, headerIterator, headerNameCount, headerNameSet, headers, headerSet, setHeader, toStringMethods inherited from class org.omegazero.common.util.SimpleAttachmentContainer
getAttachment, hasAttachment, removeAttachment, setAttachmentMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.omegazero.common.util.AttachmentContainer
requireAttachment
-
Constructor Details
-
ProxyHTTPRequest
public ProxyHTTPRequest(String method, String scheme, String authority, String path, String version, org.omegazero.http.common.HTTPHeaderContainer headers) SeeHTTPRequest(String, String, String, String, String, HTTPHeaderContainer).- Parameters:
method- The request methodscheme- The request URL schemeauthority- The request URL authoritypath- The request URL path componentversion- The HTTP versionheaders- The HTTP headers
-
ProxyHTTPRequest
SeeHTTPRequest(HTTPRequest).- Parameters:
request- TheProxyHTTPRequestto copy from
-
-
Method Details
-
respondError
Responds to thisHTTPRequestwith an error message.- Parameters:
status- The status code of the responsemessage- Error messageheaders- Headers to send in the response- See Also:
-
respondError
Responds to thisHTTPRequestwith an error message.- Parameters:
status- The status code of the responsetitle- Title of the error messagemessage- Error messageheaders- Headers to send in the response- See Also:
-
getRequestId
Returns the request ID of thisProxyHTTPRequest.- Returns:
- The request ID
-
getInitialMethod
Returns the initial HTTP request method. SeeHTTPRequest.getMethod().- Returns:
- The initial HTTP request method
-
getInitialScheme
Returns the initial HTTP request scheme. SeeHTTPRequest.getScheme().- Returns:
- The initial HTTP request scheme
-
getInitialAuthority
Returns the initial HTTP request authority. SeeHTTPRequest.getAuthority().- Returns:
- The initial HTTP request authority
-
getInitialPath
Returns the initial HTTP request path. SeeHTTPRequest.getPath().- Returns:
- The initial HTTP request path
-
getInitialHttpVersion
Returns the initial HTTP version. SeeHTTPMessage.getHttpVersion().- Returns:
- The initial HTTP version
-