Response
Constructor Summary
Public Constructor | ||
public |
constructor(client: Object, request: Request, event: Object) |
Member Summary
Protected Members | ||
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
|
protected |
|
Private Members | ||
private |
|
|
private |
|
|
private |
_contentPromise: Promise<Buffer> |
|
private |
|
|
private |
_purl: URL |
|
private |
|
|
private |
|
|
private |
|
Method Summary
Public Methods | ||
public |
|
|
public |
|
|
public |
|
|
public |
|
|
public |
|
|
public |
|
|
public |
|
|
public |
|
|
public |
|
|
public |
Returns the value for the supplied header (case insensitive) if it exists |
|
public |
|
|
public |
Returns the responses (status line and headers with CRLF) as sent by the browser if they were included with the response |
|
public |
|
|
public |
|
|
public |
|
|
public |
Returns the normalized (header keys lowercase) HTTP headers as sent by the browser. |
|
public |
|
|
public |
parsedURL(): URL |
|
public |
|
|
public |
remoteAddress(): {port: number, ip: string} |
|
public |
|
|
public |
remotePort(): number |
|
public |
|
|
public |
Returns the full request (the one generating this response) HTTP headers as sent by the browser if they were included with the response |
|
public |
Returns the full request's (the one generating this response) HTTP headers (request line and headers with CRLF) as sent by the browser if they were included with the response |
|
public |
|
|
public |
|
|
public |
|
|
public |
|
|
public |
statusLine(noHTTP2Plus: boolean): string |
|
public |
statusLineAndHeaders(noHTTP2Plus: boolean): string |
|
public |
statusText(): string |
|
public |
|
|
public |
|
|
public |
|
|
public |
toJSON(): {headers: Object, securityDetails: SecurityDetails, frameId: string, connectionReused: boolean, timing: Object, loaderId: string, encodedDataLength: number, remotePort: number, mimeType: string, type: string, headersText: ?string, securityState: string, url: string, requestHeadersText: ?string, protocol: string, requestHeaders: ?Object, fromDiskCache: boolean, fromServiceWorker: boolean, remoteIPAddress: string, requestId: string, statusText: string, timestamp: number, status: number} |
|
public |
|
|
public |
|
Public Constructors
Protected Members
Private Members
private _bodyLoadedPromise: * source
private _purl: URL source
private _securityDetails: SecurityDetails source
Public Methods
public header(header: string): string source
Returns the value for the supplied header (case insensitive) if it exists
Params:
Name | Type | Attribute | Description |
header | string |
public headersText(): string source
Returns the responses (status line and headers with CRLF) as sent by the browser if they were included with the response
public normalizedHeaders(): Object source
Returns the normalized (header keys lowercase) HTTP headers as sent by the browser.
public requestHeaders(): Object source
Returns the full request (the one generating this response) HTTP headers as sent by the browser if they were included with the response
public requestHeadersText(): string source
Returns the full request's (the one generating this response) HTTP headers (request line and headers with CRLF) as sent by the browser if they were included with the response
public statusLine(noHTTP2Plus: boolean): string source
Params:
Name | Type | Attribute | Description |
noHTTP2Plus | boolean |
|
When true if the request was made via HTTP2 the protocol is forced to HTTP/1.1 |
public statusLineAndHeaders(noHTTP2Plus: boolean): string source
Params:
Name | Type | Attribute | Description |
noHTTP2Plus | boolean |
|
When true if the request was made via HTTP2 the protocol is forced to HTTP/1.1 |
public toJSON(): {headers: Object, securityDetails: SecurityDetails, frameId: string, connectionReused: boolean, timing: Object, loaderId: string, encodedDataLength: number, remotePort: number, mimeType: string, type: string, headersText: ?string, securityState: string, url: string, requestHeadersText: ?string, protocol: string, requestHeaders: ?Object, fromDiskCache: boolean, fromServiceWorker: boolean, remoteIPAddress: string, requestId: string, statusText: string, timestamp: number, status: number} source
Return:
{headers: Object, securityDetails: SecurityDetails, frameId: string, connectionReused: boolean, timing: Object, loaderId: string, encodedDataLength: number, remotePort: number, mimeType: string, type: string, headersText: ?string, securityState: string, url: string, requestHeadersText: ?string, protocol: string, requestHeaders: ?Object, fromDiskCache: boolean, fromServiceWorker: boolean, remoteIPAddress: string, requestId: string, statusText: string, timestamp: number, status: number} |