class LocalizedMessage extends Message

Provides a localized error message that is safe to return to the user which can be attached to an RPC error.

Generated from protobuf message google.rpc.LocalizedMessage

Methods

__construct(array $data = NULL)

Constructor.

string
getLocale()

The locale used following the specification defined at http://www.rfc-editor.org/rfc/bcp/bcp47.txt.

$this
setLocale(string $var)

The locale used following the specification defined at http://www.rfc-editor.org/rfc/bcp/bcp47.txt.

string
getMessage()

The localized error message in the above locale.

$this
setMessage(string $var)

The localized error message in the above locale.

Details

at line 48
__construct(array $data = NULL)

Constructor.

Parameters

array $data { Optional. Data for populating the Message object.

@type string $locale
      The locale used following the specification defined at
      http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
      Examples are: "en-US", "fr-CH", "es-MX"
@type string $message
      The localized error message in the above locale.

}

at line 61
string getLocale()

The locale used following the specification defined at http://www.rfc-editor.org/rfc/bcp/bcp47.txt.

Examples are: "en-US", "fr-CH", "es-MX"

Generated from protobuf field string locale = 1;

Return Value

string

at line 75
$this setLocale(string $var)

The locale used following the specification defined at http://www.rfc-editor.org/rfc/bcp/bcp47.txt.

Examples are: "en-US", "fr-CH", "es-MX"

Generated from protobuf field string locale = 1;

Parameters

string $var

Return Value

$this

at line 89
string getMessage()

The localized error message in the above locale.

Generated from protobuf field string message = 2;

Return Value

string

at line 101
$this setMessage(string $var)

The localized error message in the above locale.

Generated from protobuf field string message = 2;

Parameters

string $var

Return Value

$this