| 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 message type. |
| 15 |
* |
| 16 |
* Generated from protobuf message <code>google.protobuf.DescriptorProto</code> |
| 17 |
*/ |
| 18 |
class DescriptorProto extends \Google\Protobuf\Internal\Message |
| 19 |
{ |
| 20 |
/** |
| 21 |
* Generated from protobuf field <code>optional string name = 1;</code> |
| 22 |
*/ |
| 23 |
protected $name = null; |
| 24 |
/** |
| 25 |
* Generated from protobuf field <code>repeated .google.protobuf.FieldDescriptorProto field = 2;</code> |
| 26 |
*/ |
| 27 |
private $field; |
| 28 |
/** |
| 29 |
* Generated from protobuf field <code>repeated .google.protobuf.FieldDescriptorProto extension = 6;</code> |
| 30 |
*/ |
| 31 |
private $extension; |
| 32 |
/** |
| 33 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto nested_type = 3;</code> |
| 34 |
*/ |
| 35 |
private $nested_type; |
| 36 |
/** |
| 37 |
* Generated from protobuf field <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 4;</code> |
| 38 |
*/ |
| 39 |
private $enum_type; |
| 40 |
/** |
| 41 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;</code> |
| 42 |
*/ |
| 43 |
private $extension_range; |
| 44 |
/** |
| 45 |
* Generated from protobuf field <code>repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;</code> |
| 46 |
*/ |
| 47 |
private $oneof_decl; |
| 48 |
/** |
| 49 |
* Generated from protobuf field <code>optional .google.protobuf.MessageOptions options = 7;</code> |
| 50 |
*/ |
| 51 |
protected $options = null; |
| 52 |
/** |
| 53 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;</code> |
| 54 |
*/ |
| 55 |
private $reserved_range; |
| 56 |
/** |
| 57 |
* Reserved field names, which may not be used by fields in the same message. |
| 58 |
* A given name may only be reserved once. |
| 59 |
* |
| 60 |
* Generated from protobuf field <code>repeated string reserved_name = 10;</code> |
| 61 |
*/ |
| 62 |
private $reserved_name; |
| 63 |
|
| 64 |
/** |
| 65 |
* Constructor. |
| 66 |
* |
| 67 |
* @param array $data { |
| 68 |
* Optional. Data for populating the Message object. |
| 69 |
* |
| 70 |
* @type string $name |
| 71 |
* @type array<\Google\Protobuf\Internal\FieldDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $field |
| 72 |
* @type array<\Google\Protobuf\Internal\FieldDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $extension |
| 73 |
* @type array<\Google\Protobuf\Internal\DescriptorProto>|\Google\Protobuf\Internal\RepeatedField $nested_type |
| 74 |
* @type array<\Google\Protobuf\Internal\EnumDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $enum_type |
| 75 |
* @type array<\Google\Protobuf\Internal\DescriptorProto\ExtensionRange>|\Google\Protobuf\Internal\RepeatedField $extension_range |
| 76 |
* @type array<\Google\Protobuf\Internal\OneofDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $oneof_decl |
| 77 |
* @type \Google\Protobuf\Internal\MessageOptions $options |
| 78 |
* @type array<\Google\Protobuf\Internal\DescriptorProto\ReservedRange>|\Google\Protobuf\Internal\RepeatedField $reserved_range |
| 79 |
* @type array<string>|\Google\Protobuf\Internal\RepeatedField $reserved_name |
| 80 |
* Reserved field names, which may not be used by fields in the same message. |
| 81 |
* A given name may only be reserved once. |
| 82 |
* } |
| 83 |
*/ |
| 84 |
public function __construct($data = NULL) { |
| 85 |
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
| 86 |
parent::__construct($data); |
| 87 |
} |
| 88 |
|
| 89 |
/** |
| 90 |
* Generated from protobuf field <code>optional string name = 1;</code> |
| 91 |
* @return string |
| 92 |
*/ |
| 93 |
public function getName() |
| 94 |
{ |
| 95 |
return isset($this->name) ? $this->name : ''; |
| 96 |
} |
| 97 |
|
| 98 |
public function hasName() |
| 99 |
{ |
| 100 |
return isset($this->name); |
| 101 |
} |
| 102 |
|
| 103 |
public function clearName() |
| 104 |
{ |
| 105 |
unset($this->name); |
| 106 |
} |
| 107 |
|
| 108 |
/** |
| 109 |
* Generated from protobuf field <code>optional string name = 1;</code> |
| 110 |
* @param string $var |
| 111 |
* @return $this |
| 112 |
*/ |
| 113 |
public function setName($var) |
| 114 |
{ |
| 115 |
GPBUtil::checkString($var, True); |
| 116 |
$this->name = $var; |
| 117 |
|
| 118 |
return $this; |
| 119 |
} |
| 120 |
|
| 121 |
/** |
| 122 |
* Generated from protobuf field <code>repeated .google.protobuf.FieldDescriptorProto field = 2;</code> |
| 123 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 124 |
*/ |
| 125 |
public function getField() |
| 126 |
{ |
| 127 |
return $this->field; |
| 128 |
} |
| 129 |
|
| 130 |
/** |
| 131 |
* Generated from protobuf field <code>repeated .google.protobuf.FieldDescriptorProto field = 2;</code> |
| 132 |
* @param array<\Google\Protobuf\Internal\FieldDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $var |
| 133 |
* @return $this |
| 134 |
*/ |
| 135 |
public function setField($var) |
| 136 |
{ |
| 137 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\FieldDescriptorProto::class); |
| 138 |
$this->field = $arr; |
| 139 |
|
| 140 |
return $this; |
| 141 |
} |
| 142 |
|
| 143 |
/** |
| 144 |
* Generated from protobuf field <code>repeated .google.protobuf.FieldDescriptorProto extension = 6;</code> |
| 145 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 146 |
*/ |
| 147 |
public function getExtension() |
| 148 |
{ |
| 149 |
return $this->extension; |
| 150 |
} |
| 151 |
|
| 152 |
/** |
| 153 |
* Generated from protobuf field <code>repeated .google.protobuf.FieldDescriptorProto extension = 6;</code> |
| 154 |
* @param array<\Google\Protobuf\Internal\FieldDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $var |
| 155 |
* @return $this |
| 156 |
*/ |
| 157 |
public function setExtension($var) |
| 158 |
{ |
| 159 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\FieldDescriptorProto::class); |
| 160 |
$this->extension = $arr; |
| 161 |
|
| 162 |
return $this; |
| 163 |
} |
| 164 |
|
| 165 |
/** |
| 166 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto nested_type = 3;</code> |
| 167 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 168 |
*/ |
| 169 |
public function getNestedType() |
| 170 |
{ |
| 171 |
return $this->nested_type; |
| 172 |
} |
| 173 |
|
| 174 |
/** |
| 175 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto nested_type = 3;</code> |
| 176 |
* @param array<\Google\Protobuf\Internal\DescriptorProto>|\Google\Protobuf\Internal\RepeatedField $var |
| 177 |
* @return $this |
| 178 |
*/ |
| 179 |
public function setNestedType($var) |
| 180 |
{ |
| 181 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\DescriptorProto::class); |
| 182 |
$this->nested_type = $arr; |
| 183 |
|
| 184 |
return $this; |
| 185 |
} |
| 186 |
|
| 187 |
/** |
| 188 |
* Generated from protobuf field <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 4;</code> |
| 189 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 190 |
*/ |
| 191 |
public function getEnumType() |
| 192 |
{ |
| 193 |
return $this->enum_type; |
| 194 |
} |
| 195 |
|
| 196 |
/** |
| 197 |
* Generated from protobuf field <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 4;</code> |
| 198 |
* @param array<\Google\Protobuf\Internal\EnumDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $var |
| 199 |
* @return $this |
| 200 |
*/ |
| 201 |
public function setEnumType($var) |
| 202 |
{ |
| 203 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\EnumDescriptorProto::class); |
| 204 |
$this->enum_type = $arr; |
| 205 |
|
| 206 |
return $this; |
| 207 |
} |
| 208 |
|
| 209 |
/** |
| 210 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;</code> |
| 211 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 212 |
*/ |
| 213 |
public function getExtensionRange() |
| 214 |
{ |
| 215 |
return $this->extension_range; |
| 216 |
} |
| 217 |
|
| 218 |
/** |
| 219 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;</code> |
| 220 |
* @param array<\Google\Protobuf\Internal\DescriptorProto\ExtensionRange>|\Google\Protobuf\Internal\RepeatedField $var |
| 221 |
* @return $this |
| 222 |
*/ |
| 223 |
public function setExtensionRange($var) |
| 224 |
{ |
| 225 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\DescriptorProto\ExtensionRange::class); |
| 226 |
$this->extension_range = $arr; |
| 227 |
|
| 228 |
return $this; |
| 229 |
} |
| 230 |
|
| 231 |
/** |
| 232 |
* Generated from protobuf field <code>repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;</code> |
| 233 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 234 |
*/ |
| 235 |
public function getOneofDecl() |
| 236 |
{ |
| 237 |
return $this->oneof_decl; |
| 238 |
} |
| 239 |
|
| 240 |
/** |
| 241 |
* Generated from protobuf field <code>repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;</code> |
| 242 |
* @param array<\Google\Protobuf\Internal\OneofDescriptorProto>|\Google\Protobuf\Internal\RepeatedField $var |
| 243 |
* @return $this |
| 244 |
*/ |
| 245 |
public function setOneofDecl($var) |
| 246 |
{ |
| 247 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\OneofDescriptorProto::class); |
| 248 |
$this->oneof_decl = $arr; |
| 249 |
|
| 250 |
return $this; |
| 251 |
} |
| 252 |
|
| 253 |
/** |
| 254 |
* Generated from protobuf field <code>optional .google.protobuf.MessageOptions options = 7;</code> |
| 255 |
* @return \Google\Protobuf\Internal\MessageOptions|null |
| 256 |
*/ |
| 257 |
public function getOptions() |
| 258 |
{ |
| 259 |
return $this->options; |
| 260 |
} |
| 261 |
|
| 262 |
public function hasOptions() |
| 263 |
{ |
| 264 |
return isset($this->options); |
| 265 |
} |
| 266 |
|
| 267 |
public function clearOptions() |
| 268 |
{ |
| 269 |
unset($this->options); |
| 270 |
} |
| 271 |
|
| 272 |
/** |
| 273 |
* Generated from protobuf field <code>optional .google.protobuf.MessageOptions options = 7;</code> |
| 274 |
* @param \Google\Protobuf\Internal\MessageOptions $var |
| 275 |
* @return $this |
| 276 |
*/ |
| 277 |
public function setOptions($var) |
| 278 |
{ |
| 279 |
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\MessageOptions::class); |
| 280 |
$this->options = $var; |
| 281 |
|
| 282 |
return $this; |
| 283 |
} |
| 284 |
|
| 285 |
/** |
| 286 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;</code> |
| 287 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 288 |
*/ |
| 289 |
public function getReservedRange() |
| 290 |
{ |
| 291 |
return $this->reserved_range; |
| 292 |
} |
| 293 |
|
| 294 |
/** |
| 295 |
* Generated from protobuf field <code>repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;</code> |
| 296 |
* @param array<\Google\Protobuf\Internal\DescriptorProto\ReservedRange>|\Google\Protobuf\Internal\RepeatedField $var |
| 297 |
* @return $this |
| 298 |
*/ |
| 299 |
public function setReservedRange($var) |
| 300 |
{ |
| 301 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\DescriptorProto\ReservedRange::class); |
| 302 |
$this->reserved_range = $arr; |
| 303 |
|
| 304 |
return $this; |
| 305 |
} |
| 306 |
|
| 307 |
/** |
| 308 |
* Reserved field names, which may not be used by fields in the same message. |
| 309 |
* A given name may only be reserved once. |
| 310 |
* |
| 311 |
* Generated from protobuf field <code>repeated string reserved_name = 10;</code> |
| 312 |
* @return \Google\Protobuf\Internal\RepeatedField |
| 313 |
*/ |
| 314 |
public function getReservedName() |
| 315 |
{ |
| 316 |
return $this->reserved_name; |
| 317 |
} |
| 318 |
|
| 319 |
/** |
| 320 |
* Reserved field names, which may not be used by fields in the same message. |
| 321 |
* A given name may only be reserved once. |
| 322 |
* |
| 323 |
* Generated from protobuf field <code>repeated string reserved_name = 10;</code> |
| 324 |
* @param array<string>|\Google\Protobuf\Internal\RepeatedField $var |
| 325 |
* @return $this |
| 326 |
*/ |
| 327 |
public function setReservedName($var) |
| 328 |
{ |
| 329 |
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); |
| 330 |
$this->reserved_name = $arr; |
| 331 |
|
| 332 |
return $this; |
| 333 |
} |
| 334 |
|
| 335 |
} |
| 336 |
|