Debian Codegraph @

php/src/Google/Protobuf/Internal/EnumDescriptorProto/EnumReservedRange.php

raw
1 <?php
2 # Generated by the protocol buffer compiler. DO NOT EDIT!
3 # source: google/protobuf/descriptor.proto
4
5 namespace Google\Protobuf\Internal\EnumDescriptorProto;
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 * Range of reserved numeric values. Reserved values may not be used by
15 * entries in the same enum. Reserved ranges may not overlap.
16 * Note that this is distinct from DescriptorProto.ReservedRange in that it
17 * is inclusive such that it can appropriately represent the entire int32
18 * domain.
19 *
20 * Generated from protobuf message <code>google.protobuf.EnumDescriptorProto.EnumReservedRange</code>
21 */
22 class EnumReservedRange extends \Google\Protobuf\Internal\Message
23 {
24 /**
25 * Inclusive.
26 *
27 * Generated from protobuf field <code>optional int32 start = 1;</code>
28 */
29 protected $start = null;
30 /**
31 * Inclusive.
32 *
33 * Generated from protobuf field <code>optional int32 end = 2;</code>
34 */
35 protected $end = null;
36
37 /**
38 * Constructor.
39 *
40 * @param array $data {
41 * Optional. Data for populating the Message object.
42 *
43 * @type int $start
44 * Inclusive.
45 * @type int $end
46 * Inclusive.
47 * }
48 */
49 public function __construct($data = NULL) {
50 \GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce();
51 parent::__construct($data);
52 }
53
54 /**
55 * Inclusive.
56 *
57 * Generated from protobuf field <code>optional int32 start = 1;</code>
58 * @return int
59 */
60 public function getStart()
61 {
62 return isset($this->start) ? $this->start : 0;
63 }
64
65 public function hasStart()
66 {
67 return isset($this->start);
68 }
69
70 public function clearStart()
71 {
72 unset($this->start);
73 }
74
75 /**
76 * Inclusive.
77 *
78 * Generated from protobuf field <code>optional int32 start = 1;</code>
79 * @param int $var
80 * @return $this
81 */
82 public function setStart($var)
83 {
84 GPBUtil::checkInt32($var);
85 $this->start = $var;
86
87 return $this;
88 }
89
90 /**
91 * Inclusive.
92 *
93 * Generated from protobuf field <code>optional int32 end = 2;</code>
94 * @return int
95 */
96 public function getEnd()
97 {
98 return isset($this->end) ? $this->end : 0;
99 }
100
101 public function hasEnd()
102 {
103 return isset($this->end);
104 }
105
106 public function clearEnd()
107 {
108 unset($this->end);
109 }
110
111 /**
112 * Inclusive.
113 *
114 * Generated from protobuf field <code>optional int32 end = 2;</code>
115 * @param int $var
116 * @return $this
117 */
118 public function setEnd($var)
119 {
120 GPBUtil::checkInt32($var);
121 $this->end = $var;
122
123 return $this;
124 }
125
126 }
127
128 // Adding a class alias for backwards compatibility with the previous class name.
129 class_alias(EnumReservedRange::class, \Google\Protobuf\Internal\EnumDescriptorProto_EnumReservedRange::class);
130