Stackdriver Error Reporting V1beta1 Client - Class HttpRequestContext (0.22.6)

Reference documentation and code samples for the Stackdriver Error Reporting V1beta1 Client class HttpRequestContext.

HTTP request data that is related to a reported error.

This data should be provided by the application when reporting an error, unless the error report has been generated automatically from Google App Engine logs.

Generated from protobuf message google.devtools.clouderrorreporting.v1beta1.HttpRequestContext

Namespace

Google \ Cloud \ ErrorReporting \ V1beta1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ method string

The type of HTTP request, such as GET, POST, etc.

↳ url string

The URL of the request.

↳ user_agent string

The user agent information that is provided with the request.

↳ referrer string

The referrer information that is provided with the request.

↳ response_status_code int

The HTTP response status code for the request.

↳ remote_ip string

The IP address from which the request originated. This can be IPv4, IPv6, or a token which is derived from the IP address, depending on the data that has been provided in the error report.

getMethod

The type of HTTP request, such as GET, POST, etc.

Returns
Type Description
string

setMethod

The type of HTTP request, such as GET, POST, etc.

Parameter
Name Description
var string
Returns
Type Description
$this

getUrl

The URL of the request.

Returns
Type Description
string

setUrl

The URL of the request.

Parameter
Name Description
var string
Returns
Type Description
$this

getUserAgent

The user agent information that is provided with the request.

Returns
Type Description
string

setUserAgent

The user agent information that is provided with the request.

Parameter
Name Description
var string
Returns
Type Description
$this

getReferrer

The referrer information that is provided with the request.

Returns
Type Description
string

setReferrer

The referrer information that is provided with the request.

Parameter
Name Description
var string
Returns
Type Description
$this

getResponseStatusCode

The HTTP response status code for the request.

Returns
Type Description
int

setResponseStatusCode

The HTTP response status code for the request.

Parameter
Name Description
var int
Returns
Type Description
$this

getRemoteIp

The IP address from which the request originated.

This can be IPv4, IPv6, or a token which is derived from the IP address, depending on the data that has been provided in the error report.

Returns
Type Description
string

setRemoteIp

The IP address from which the request originated.

This can be IPv4, IPv6, or a token which is derived from the IP address, depending on the data that has been provided in the error report.

Parameter
Name Description
var string
Returns
Type Description
$this