function Option::setValue
The option's value packed in an Any message. If the value is a primitive, the corresponding wrapper type defined in google/protobuf/wrappers.proto should be used. If the value is an enum, it should be stored as an int32 value using the google.protobuf.Int32Value type.
Generated from protobuf field <code>.google.protobuf.Any value = 2;</code>
Parameters
\Google\Protobuf\Any $var:
Return value
$this
File
-
vendor/
google/ protobuf/ src/ Google/ Protobuf/ Option.php, line 127
Class
- Option
- A protocol buffer option, which can be attached to a message, field, enumeration, etc.
Namespace
Google\ProtobufCode
public function setValue($var) {
GPBUtil::checkMessage($var, \Google\Protobuf\Any::class);
$this->value = $var;
return $this;
}