| <?php | |
| # Generated by the protocol buffer compiler. DO NOT EDIT! | |
| # NO CHECKED-IN PROTOBUF GENCODE | |
| # source: google/protobuf/descriptor.proto | |
| namespace Google\Protobuf\Internal; | |
| use Google\Protobuf\Internal\GPBType; | |
| use Google\Protobuf\Internal\GPBWire; | |
| use Google\Protobuf\Internal\InputStream; | |
| use Google\Protobuf\Internal\GPBUtil; | |
| use Google\Protobuf\RepeatedField; | |
| /** | |
| * Describes an enum type. | |
| * | |
| * Generated from protobuf message <code>google.protobuf.EnumDescriptorProto</code> | |
| */ | |
| class EnumDescriptorProto extends \Google\Protobuf\Internal\Message | |
| { | |
| /** | |
| * Generated from protobuf field <code>optional string name = 1;</code> | |
| */ | |
| protected $name = null; | |
| /** | |
| * Generated from protobuf field <code>repeated .google.protobuf.EnumValueDescriptorProto value = 2;</code> | |
| */ | |
| private $value; | |
| /** | |
| * Generated from protobuf field <code>optional .google.protobuf.EnumOptions options = 3;</code> | |
| */ | |
| protected $options = null; | |
| /** | |
| * Range of reserved numeric values. Reserved numeric values may not be used | |
| * by enum values in the same enum declaration. Reserved ranges may not | |
| * overlap. | |
| * | |
| * Generated from protobuf field <code>repeated .google.protobuf.EnumDescriptorProto.EnumReservedRange reserved_range = 4;</code> | |
| */ | |
| private $reserved_range; | |
| /** | |
| * Reserved enum value names, which may not be reused. A given name may only | |
| * be reserved once. | |
| * | |
| * Generated from protobuf field <code>repeated string reserved_name = 5;</code> | |
| */ | |
| private $reserved_name; | |
| /** | |
| * Support for `export` and `local` keywords on enums. | |
| * | |
| * Generated from protobuf field <code>optional .google.protobuf.SymbolVisibility visibility = 6;</code> | |
| */ | |
| protected $visibility = null; | |
| /** | |
| * Constructor. | |
| * | |
| * @param array $data { | |
| * Optional. Data for populating the Message object. | |
| * | |
| * @type string $name | |
| * @type \Google\Protobuf\Internal\EnumValueDescriptorProto[] $value | |
| * @type \Google\Protobuf\Internal\EnumOptions $options | |
| * @type \Google\Protobuf\Internal\EnumDescriptorProto\EnumReservedRange[] $reserved_range | |
| * Range of reserved numeric values. Reserved numeric values may not be used | |
| * by enum values in the same enum declaration. Reserved ranges may not | |
| * overlap. | |
| * @type string[] $reserved_name | |
| * Reserved enum value names, which may not be reused. A given name may only | |
| * be reserved once. | |
| * @type int $visibility | |
| * Support for `export` and `local` keywords on enums. | |
| * } | |
| */ | |
| public function __construct($data = null) | |
| { | |
| \GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); | |
| parent::__construct($data); | |
| } | |
| /** | |
| * Generated from protobuf field <code>optional string name = 1;</code> | |
| * @return string | |
| */ | |
| public function getName() | |
| { | |
| return isset($this->name) ? $this->name : ''; | |
| } | |
| public function hasName() | |
| { | |
| return isset($this->name); | |
| } | |
| public function clearName() | |
| { | |
| unset($this->name); | |
| } | |
| /** | |
| * Generated from protobuf field <code>optional string name = 1;</code> | |
| * @param string $var | |
| * @return $this | |
| */ | |
| public function setName(string $var) | |
| { | |
| GPBUtil::checkString($var, true); | |
| $this->name = $var; | |
| return $this; | |
| } | |
| /** | |
| * Generated from protobuf field <code>repeated .google.protobuf.EnumValueDescriptorProto value = 2;</code> | |
| * @return RepeatedField<\Google\Protobuf\Internal\EnumValueDescriptorProto> | |
| */ | |
| public function getValue() | |
| { | |
| return $this->value; | |
| } | |
| /** | |
| * Generated from protobuf field <code>repeated .google.protobuf.EnumValueDescriptorProto value = 2;</code> | |
| * @param \Google\Protobuf\Internal\EnumValueDescriptorProto[] $var | |
| * @return $this | |
| */ | |
| public function setValue(array|RepeatedField $var) | |
| { | |
| $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\EnumValueDescriptorProto::class); | |
| $this->value = $arr; | |
| return $this; | |
| } | |
| /** | |
| * Generated from protobuf field <code>optional .google.protobuf.EnumOptions options = 3;</code> | |
| * @return \Google\Protobuf\Internal\EnumOptions|null | |
| */ | |
| public function getOptions() | |
| { | |
| return $this->options; | |
| } | |
| public function hasOptions() | |
| { | |
| return isset($this->options); | |
| } | |
| public function clearOptions() | |
| { | |
| unset($this->options); | |
| } | |
| /** | |
| * Generated from protobuf field <code>optional .google.protobuf.EnumOptions options = 3;</code> | |
| * @param \Google\Protobuf\Internal\EnumOptions $var | |
| * @return $this | |
| */ | |
| public function setOptions(\Google\Protobuf\Internal\EnumOptions|null $var) | |
| { | |
| $this->options = $var; | |
| return $this; | |
| } | |
| /** | |
| * Range of reserved numeric values. Reserved numeric values may not be used | |
| * by enum values in the same enum declaration. Reserved ranges may not | |
| * overlap. | |
| * | |
| * Generated from protobuf field <code>repeated .google.protobuf.EnumDescriptorProto.EnumReservedRange reserved_range = 4;</code> | |
| * @return RepeatedField<\Google\Protobuf\Internal\EnumDescriptorProto\EnumReservedRange> | |
| */ | |
| public function getReservedRange() | |
| { | |
| return $this->reserved_range; | |
| } | |
| /** | |
| * Range of reserved numeric values. Reserved numeric values may not be used | |
| * by enum values in the same enum declaration. Reserved ranges may not | |
| * overlap. | |
| * | |
| * Generated from protobuf field <code>repeated .google.protobuf.EnumDescriptorProto.EnumReservedRange reserved_range = 4;</code> | |
| * @param \Google\Protobuf\Internal\EnumDescriptorProto\EnumReservedRange[] $var | |
| * @return $this | |
| */ | |
| public function setReservedRange(array|RepeatedField $var) | |
| { | |
| $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\EnumDescriptorProto\EnumReservedRange::class); | |
| $this->reserved_range = $arr; | |
| return $this; | |
| } | |
| /** | |
| * Reserved enum value names, which may not be reused. A given name may only | |
| * be reserved once. | |
| * | |
| * Generated from protobuf field <code>repeated string reserved_name = 5;</code> | |
| * @return RepeatedField<string> | |
| */ | |
| public function getReservedName() | |
| { | |
| return $this->reserved_name; | |
| } | |
| /** | |
| * Reserved enum value names, which may not be reused. A given name may only | |
| * be reserved once. | |
| * | |
| * Generated from protobuf field <code>repeated string reserved_name = 5;</code> | |
| * @param string[] $var | |
| * @return $this | |
| */ | |
| public function setReservedName(array|RepeatedField $var) | |
| { | |
| $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); | |
| $this->reserved_name = $arr; | |
| return $this; | |
| } | |
| /** | |
| * Support for `export` and `local` keywords on enums. | |
| * | |
| * Generated from protobuf field <code>optional .google.protobuf.SymbolVisibility visibility = 6;</code> | |
| * @return int one of the values in {@see \Google\Protobuf\Internal\SymbolVisibility} | |
| */ | |
| public function getVisibility() | |
| { | |
| return isset($this->visibility) ? $this->visibility : 0; | |
| } | |
| public function hasVisibility() | |
| { | |
| return isset($this->visibility); | |
| } | |
| public function clearVisibility() | |
| { | |
| unset($this->visibility); | |
| } | |
| /** | |
| * Support for `export` and `local` keywords on enums. | |
| * | |
| * Generated from protobuf field <code>optional .google.protobuf.SymbolVisibility visibility = 6;</code> | |
| * @param int $var one of the values in {@see \Google\Protobuf\Internal\SymbolVisibility} | |
| * @return $this | |
| */ | |
| public function setVisibility(int $var) | |
| { | |
| GPBUtil::checkEnum($var, \Google\Protobuf\Internal\SymbolVisibility::class); | |
| $this->visibility = $var; | |
| return $this; | |
| } | |
| } | |