google.api.servicecontrol.v1.CheckError */ class CheckError extends \Google\Protobuf\Internal\Message { /** * The error code. * * Generated from protobuf field .google.api.servicecontrol.v1.CheckError.Code code = 1; */ private $code = 0; /** * Free-form text providing details on the error cause of the error. * * Generated from protobuf field string detail = 2; */ private $detail = ''; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type int $code * The error code. * @type string $detail * Free-form text providing details on the error cause of the error. * } */ public function __construct($data = NULL) { \GPBMetadata\Google\Api\Servicecontrol\V1\CheckError::initOnce(); parent::__construct($data); } /** * The error code. * * Generated from protobuf field .google.api.servicecontrol.v1.CheckError.Code code = 1; * @return int */ public function getCode() { return $this->code; } /** * The error code. * * Generated from protobuf field .google.api.servicecontrol.v1.CheckError.Code code = 1; * @param int $var * @return $this */ public function setCode($var) { GPBUtil::checkEnum($var, \Google\Api\Servicecontrol\V1\CheckError_Code::class); $this->code = $var; return $this; } /** * Free-form text providing details on the error cause of the error. * * Generated from protobuf field string detail = 2; * @return string */ public function getDetail() { return $this->detail; } /** * Free-form text providing details on the error cause of the error. * * Generated from protobuf field string detail = 2; * @param string $var * @return $this */ public function setDetail($var) { GPBUtil::checkString($var, True); $this->detail = $var; return $this; } }