avm99963 | 99bb77c | 2020-01-27 03:15:08 +0100 | [diff] [blame^] | 1 | <?php |
| 2 | # Generated by the protocol buffer compiler. DO NOT EDIT! |
| 3 | # source: google/protobuf/descriptor.proto |
| 4 | |
| 5 | namespace Google\Protobuf\Internal; |
| 6 | |
| 7 | use Google\Protobuf\Internal\GPBType; |
| 8 | use Google\Protobuf\Internal\GPBWire; |
| 9 | use Google\Protobuf\Internal\RepeatedField; |
| 10 | use Google\Protobuf\Internal\InputStream; |
| 11 | use Google\Protobuf\Internal\GPBUtil; |
| 12 | |
| 13 | /** |
| 14 | * Describes a value within an enum. |
| 15 | * |
| 16 | * Generated from protobuf message <code>google.protobuf.EnumValueDescriptorProto</code> |
| 17 | */ |
| 18 | class EnumValueDescriptorProto extends \Google\Protobuf\Internal\Message |
| 19 | { |
| 20 | /** |
| 21 | * Generated from protobuf field <code>optional string name = 1;</code> |
| 22 | */ |
| 23 | protected $name = ''; |
| 24 | private $has_name = false; |
| 25 | /** |
| 26 | * Generated from protobuf field <code>optional int32 number = 2;</code> |
| 27 | */ |
| 28 | protected $number = 0; |
| 29 | private $has_number = false; |
| 30 | /** |
| 31 | * Generated from protobuf field <code>optional .google.protobuf.EnumValueOptions options = 3;</code> |
| 32 | */ |
| 33 | protected $options = null; |
| 34 | private $has_options = false; |
| 35 | |
| 36 | /** |
| 37 | * Constructor. |
| 38 | * |
| 39 | * @param array $data { |
| 40 | * Optional. Data for populating the Message object. |
| 41 | * |
| 42 | * @type string $name |
| 43 | * @type int $number |
| 44 | * @type \Google\Protobuf\Internal\EnumValueOptions $options |
| 45 | * } |
| 46 | */ |
| 47 | public function __construct($data = NULL) { |
| 48 | \GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
| 49 | parent::__construct($data); |
| 50 | } |
| 51 | |
| 52 | /** |
| 53 | * Generated from protobuf field <code>optional string name = 1;</code> |
| 54 | * @return string |
| 55 | */ |
| 56 | public function getName() |
| 57 | { |
| 58 | return $this->name; |
| 59 | } |
| 60 | |
| 61 | /** |
| 62 | * Generated from protobuf field <code>optional string name = 1;</code> |
| 63 | * @param string $var |
| 64 | * @return $this |
| 65 | */ |
| 66 | public function setName($var) |
| 67 | { |
| 68 | GPBUtil::checkString($var, True); |
| 69 | $this->name = $var; |
| 70 | $this->has_name = true; |
| 71 | |
| 72 | return $this; |
| 73 | } |
| 74 | |
| 75 | public function hasName() |
| 76 | { |
| 77 | return $this->has_name; |
| 78 | } |
| 79 | |
| 80 | /** |
| 81 | * Generated from protobuf field <code>optional int32 number = 2;</code> |
| 82 | * @return int |
| 83 | */ |
| 84 | public function getNumber() |
| 85 | { |
| 86 | return $this->number; |
| 87 | } |
| 88 | |
| 89 | /** |
| 90 | * Generated from protobuf field <code>optional int32 number = 2;</code> |
| 91 | * @param int $var |
| 92 | * @return $this |
| 93 | */ |
| 94 | public function setNumber($var) |
| 95 | { |
| 96 | GPBUtil::checkInt32($var); |
| 97 | $this->number = $var; |
| 98 | $this->has_number = true; |
| 99 | |
| 100 | return $this; |
| 101 | } |
| 102 | |
| 103 | public function hasNumber() |
| 104 | { |
| 105 | return $this->has_number; |
| 106 | } |
| 107 | |
| 108 | /** |
| 109 | * Generated from protobuf field <code>optional .google.protobuf.EnumValueOptions options = 3;</code> |
| 110 | * @return \Google\Protobuf\Internal\EnumValueOptions |
| 111 | */ |
| 112 | public function getOptions() |
| 113 | { |
| 114 | return $this->options; |
| 115 | } |
| 116 | |
| 117 | /** |
| 118 | * Generated from protobuf field <code>optional .google.protobuf.EnumValueOptions options = 3;</code> |
| 119 | * @param \Google\Protobuf\Internal\EnumValueOptions $var |
| 120 | * @return $this |
| 121 | */ |
| 122 | public function setOptions($var) |
| 123 | { |
| 124 | GPBUtil::checkMessage($var, \Google\Protobuf\Internal\EnumValueOptions::class); |
| 125 | $this->options = $var; |
| 126 | $this->has_options = true; |
| 127 | |
| 128 | return $this; |
| 129 | } |
| 130 | |
| 131 | public function hasOptions() |
| 132 | { |
| 133 | return $this->has_options; |
| 134 | } |
| 135 | |
| 136 | } |
| 137 | |