Compute V1 Client - Class UrlRewrite (1.7.1)

Reference documentation and code samples for the Compute V1 Client class UrlRewrite.

The spec for modifying the path before sending the request to the matched backend service.

Generated from protobuf message google.cloud.compute.v1.UrlRewrite

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ host_rewrite string

Before forwarding the request to the selected service, the request's host header is replaced with contents of hostRewrite. The value must be from 1 to 255 characters.

↳ path_prefix_rewrite string

Before forwarding the request to the selected backend service, the matching portion of the request's path is replaced by pathPrefixRewrite. The value must be from 1 to 1024 characters.

getHostRewrite

Before forwarding the request to the selected service, the request's host header is replaced with contents of hostRewrite. The value must be from 1 to 255 characters.

Returns
TypeDescription
string

hasHostRewrite

clearHostRewrite

setHostRewrite

Before forwarding the request to the selected service, the request's host header is replaced with contents of hostRewrite. The value must be from 1 to 255 characters.

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getPathPrefixRewrite

Before forwarding the request to the selected backend service, the matching portion of the request's path is replaced by pathPrefixRewrite. The value must be from 1 to 1024 characters.

Returns
TypeDescription
string

hasPathPrefixRewrite

clearPathPrefixRewrite

setPathPrefixRewrite

Before forwarding the request to the selected backend service, the matching portion of the request's path is replaced by pathPrefixRewrite. The value must be from 1 to 1024 characters.

Parameter
NameDescription
var string
Returns
TypeDescription
$this