1ffe3c632Sopenharmony_ci<?php 2ffe3c632Sopenharmony_ci# Generated by the protocol buffer compiler. DO NOT EDIT! 3ffe3c632Sopenharmony_ci# source: google/protobuf/descriptor.proto 4ffe3c632Sopenharmony_ci 5ffe3c632Sopenharmony_cinamespace Google\Protobuf\Internal; 6ffe3c632Sopenharmony_ci 7ffe3c632Sopenharmony_ciuse Google\Protobuf\Internal\GPBType; 8ffe3c632Sopenharmony_ciuse Google\Protobuf\Internal\GPBWire; 9ffe3c632Sopenharmony_ciuse Google\Protobuf\Internal\RepeatedField; 10ffe3c632Sopenharmony_ciuse Google\Protobuf\Internal\InputStream; 11ffe3c632Sopenharmony_ciuse Google\Protobuf\Internal\GPBUtil; 12ffe3c632Sopenharmony_ci 13ffe3c632Sopenharmony_ci/** 14ffe3c632Sopenharmony_ci * Generated from protobuf message <code>google.protobuf.FieldOptions</code> 15ffe3c632Sopenharmony_ci */ 16ffe3c632Sopenharmony_ciclass FieldOptions extends \Google\Protobuf\Internal\Message 17ffe3c632Sopenharmony_ci{ 18ffe3c632Sopenharmony_ci /** 19ffe3c632Sopenharmony_ci * The ctype option instructs the C++ code generator to use a different 20ffe3c632Sopenharmony_ci * representation of the field than it normally would. See the specific 21ffe3c632Sopenharmony_ci * options below. This option is not yet implemented in the open source 22ffe3c632Sopenharmony_ci * release -- sorry, we'll try to include it in a future version! 23ffe3c632Sopenharmony_ci * 24ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional .google.protobuf.FieldOptions.CType ctype = 1 [default = STRING];</code> 25ffe3c632Sopenharmony_ci */ 26ffe3c632Sopenharmony_ci protected $ctype = null; 27ffe3c632Sopenharmony_ci /** 28ffe3c632Sopenharmony_ci * The packed option can be enabled for repeated primitive fields to enable 29ffe3c632Sopenharmony_ci * a more efficient representation on the wire. Rather than repeatedly 30ffe3c632Sopenharmony_ci * writing the tag and type for each element, the entire array is encoded as 31ffe3c632Sopenharmony_ci * a single length-delimited blob. In proto3, only explicit setting it to 32ffe3c632Sopenharmony_ci * false will avoid using packed encoding. 33ffe3c632Sopenharmony_ci * 34ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool packed = 2;</code> 35ffe3c632Sopenharmony_ci */ 36ffe3c632Sopenharmony_ci protected $packed = null; 37ffe3c632Sopenharmony_ci /** 38ffe3c632Sopenharmony_ci * The jstype option determines the JavaScript type used for values of the 39ffe3c632Sopenharmony_ci * field. The option is permitted only for 64 bit integral and fixed types 40ffe3c632Sopenharmony_ci * (int64, uint64, sint64, fixed64, sfixed64). A field with jstype JS_STRING 41ffe3c632Sopenharmony_ci * is represented as JavaScript string, which avoids loss of precision that 42ffe3c632Sopenharmony_ci * can happen when a large value is converted to a floating point JavaScript. 43ffe3c632Sopenharmony_ci * Specifying JS_NUMBER for the jstype causes the generated JavaScript code to 44ffe3c632Sopenharmony_ci * use the JavaScript "number" type. The behavior of the default option 45ffe3c632Sopenharmony_ci * JS_NORMAL is implementation dependent. 46ffe3c632Sopenharmony_ci * This option is an enum to permit additional types to be added, e.g. 47ffe3c632Sopenharmony_ci * goog.math.Integer. 48ffe3c632Sopenharmony_ci * 49ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL];</code> 50ffe3c632Sopenharmony_ci */ 51ffe3c632Sopenharmony_ci protected $jstype = null; 52ffe3c632Sopenharmony_ci /** 53ffe3c632Sopenharmony_ci * Should this field be parsed lazily? Lazy applies only to message-type 54ffe3c632Sopenharmony_ci * fields. It means that when the outer message is initially parsed, the 55ffe3c632Sopenharmony_ci * inner message's contents will not be parsed but instead stored in encoded 56ffe3c632Sopenharmony_ci * form. The inner message will actually be parsed when it is first accessed. 57ffe3c632Sopenharmony_ci * This is only a hint. Implementations are free to choose whether to use 58ffe3c632Sopenharmony_ci * eager or lazy parsing regardless of the value of this option. However, 59ffe3c632Sopenharmony_ci * setting this option true suggests that the protocol author believes that 60ffe3c632Sopenharmony_ci * using lazy parsing on this field is worth the additional bookkeeping 61ffe3c632Sopenharmony_ci * overhead typically needed to implement it. 62ffe3c632Sopenharmony_ci * This option does not affect the public interface of any generated code; 63ffe3c632Sopenharmony_ci * all method signatures remain the same. Furthermore, thread-safety of the 64ffe3c632Sopenharmony_ci * interface is not affected by this option; const methods remain safe to 65ffe3c632Sopenharmony_ci * call from multiple threads concurrently, while non-const methods continue 66ffe3c632Sopenharmony_ci * to require exclusive access. 67ffe3c632Sopenharmony_ci * Note that implementations may choose not to check required fields within 68ffe3c632Sopenharmony_ci * a lazy sub-message. That is, calling IsInitialized() on the outer message 69ffe3c632Sopenharmony_ci * may return true even if the inner message has missing required fields. 70ffe3c632Sopenharmony_ci * This is necessary because otherwise the inner message would have to be 71ffe3c632Sopenharmony_ci * parsed in order to perform the check, defeating the purpose of lazy 72ffe3c632Sopenharmony_ci * parsing. An implementation which chooses not to check required fields 73ffe3c632Sopenharmony_ci * must be consistent about it. That is, for any particular sub-message, the 74ffe3c632Sopenharmony_ci * implementation must either *always* check its required fields, or *never* 75ffe3c632Sopenharmony_ci * check its required fields, regardless of whether or not the message has 76ffe3c632Sopenharmony_ci * been parsed. 77ffe3c632Sopenharmony_ci * 78ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool lazy = 5 [default = false];</code> 79ffe3c632Sopenharmony_ci */ 80ffe3c632Sopenharmony_ci protected $lazy = null; 81ffe3c632Sopenharmony_ci /** 82ffe3c632Sopenharmony_ci * Is this field deprecated? 83ffe3c632Sopenharmony_ci * Depending on the target platform, this can emit Deprecated annotations 84ffe3c632Sopenharmony_ci * for accessors, or it will be completely ignored; in the very least, this 85ffe3c632Sopenharmony_ci * is a formalization for deprecating fields. 86ffe3c632Sopenharmony_ci * 87ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool deprecated = 3 [default = false];</code> 88ffe3c632Sopenharmony_ci */ 89ffe3c632Sopenharmony_ci protected $deprecated = null; 90ffe3c632Sopenharmony_ci /** 91ffe3c632Sopenharmony_ci * For Google-internal migration only. Do not use. 92ffe3c632Sopenharmony_ci * 93ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool weak = 10 [default = false];</code> 94ffe3c632Sopenharmony_ci */ 95ffe3c632Sopenharmony_ci protected $weak = null; 96ffe3c632Sopenharmony_ci /** 97ffe3c632Sopenharmony_ci * The parser stores options it doesn't recognize here. See above. 98ffe3c632Sopenharmony_ci * 99ffe3c632Sopenharmony_ci * Generated from protobuf field <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> 100ffe3c632Sopenharmony_ci */ 101ffe3c632Sopenharmony_ci private $uninterpreted_option; 102ffe3c632Sopenharmony_ci 103ffe3c632Sopenharmony_ci /** 104ffe3c632Sopenharmony_ci * Constructor. 105ffe3c632Sopenharmony_ci * 106ffe3c632Sopenharmony_ci * @param array $data { 107ffe3c632Sopenharmony_ci * Optional. Data for populating the Message object. 108ffe3c632Sopenharmony_ci * 109ffe3c632Sopenharmony_ci * @type int $ctype 110ffe3c632Sopenharmony_ci * The ctype option instructs the C++ code generator to use a different 111ffe3c632Sopenharmony_ci * representation of the field than it normally would. See the specific 112ffe3c632Sopenharmony_ci * options below. This option is not yet implemented in the open source 113ffe3c632Sopenharmony_ci * release -- sorry, we'll try to include it in a future version! 114ffe3c632Sopenharmony_ci * @type bool $packed 115ffe3c632Sopenharmony_ci * The packed option can be enabled for repeated primitive fields to enable 116ffe3c632Sopenharmony_ci * a more efficient representation on the wire. Rather than repeatedly 117ffe3c632Sopenharmony_ci * writing the tag and type for each element, the entire array is encoded as 118ffe3c632Sopenharmony_ci * a single length-delimited blob. In proto3, only explicit setting it to 119ffe3c632Sopenharmony_ci * false will avoid using packed encoding. 120ffe3c632Sopenharmony_ci * @type int $jstype 121ffe3c632Sopenharmony_ci * The jstype option determines the JavaScript type used for values of the 122ffe3c632Sopenharmony_ci * field. The option is permitted only for 64 bit integral and fixed types 123ffe3c632Sopenharmony_ci * (int64, uint64, sint64, fixed64, sfixed64). A field with jstype JS_STRING 124ffe3c632Sopenharmony_ci * is represented as JavaScript string, which avoids loss of precision that 125ffe3c632Sopenharmony_ci * can happen when a large value is converted to a floating point JavaScript. 126ffe3c632Sopenharmony_ci * Specifying JS_NUMBER for the jstype causes the generated JavaScript code to 127ffe3c632Sopenharmony_ci * use the JavaScript "number" type. The behavior of the default option 128ffe3c632Sopenharmony_ci * JS_NORMAL is implementation dependent. 129ffe3c632Sopenharmony_ci * This option is an enum to permit additional types to be added, e.g. 130ffe3c632Sopenharmony_ci * goog.math.Integer. 131ffe3c632Sopenharmony_ci * @type bool $lazy 132ffe3c632Sopenharmony_ci * Should this field be parsed lazily? Lazy applies only to message-type 133ffe3c632Sopenharmony_ci * fields. It means that when the outer message is initially parsed, the 134ffe3c632Sopenharmony_ci * inner message's contents will not be parsed but instead stored in encoded 135ffe3c632Sopenharmony_ci * form. The inner message will actually be parsed when it is first accessed. 136ffe3c632Sopenharmony_ci * This is only a hint. Implementations are free to choose whether to use 137ffe3c632Sopenharmony_ci * eager or lazy parsing regardless of the value of this option. However, 138ffe3c632Sopenharmony_ci * setting this option true suggests that the protocol author believes that 139ffe3c632Sopenharmony_ci * using lazy parsing on this field is worth the additional bookkeeping 140ffe3c632Sopenharmony_ci * overhead typically needed to implement it. 141ffe3c632Sopenharmony_ci * This option does not affect the public interface of any generated code; 142ffe3c632Sopenharmony_ci * all method signatures remain the same. Furthermore, thread-safety of the 143ffe3c632Sopenharmony_ci * interface is not affected by this option; const methods remain safe to 144ffe3c632Sopenharmony_ci * call from multiple threads concurrently, while non-const methods continue 145ffe3c632Sopenharmony_ci * to require exclusive access. 146ffe3c632Sopenharmony_ci * Note that implementations may choose not to check required fields within 147ffe3c632Sopenharmony_ci * a lazy sub-message. That is, calling IsInitialized() on the outer message 148ffe3c632Sopenharmony_ci * may return true even if the inner message has missing required fields. 149ffe3c632Sopenharmony_ci * This is necessary because otherwise the inner message would have to be 150ffe3c632Sopenharmony_ci * parsed in order to perform the check, defeating the purpose of lazy 151ffe3c632Sopenharmony_ci * parsing. An implementation which chooses not to check required fields 152ffe3c632Sopenharmony_ci * must be consistent about it. That is, for any particular sub-message, the 153ffe3c632Sopenharmony_ci * implementation must either *always* check its required fields, or *never* 154ffe3c632Sopenharmony_ci * check its required fields, regardless of whether or not the message has 155ffe3c632Sopenharmony_ci * been parsed. 156ffe3c632Sopenharmony_ci * @type bool $deprecated 157ffe3c632Sopenharmony_ci * Is this field deprecated? 158ffe3c632Sopenharmony_ci * Depending on the target platform, this can emit Deprecated annotations 159ffe3c632Sopenharmony_ci * for accessors, or it will be completely ignored; in the very least, this 160ffe3c632Sopenharmony_ci * is a formalization for deprecating fields. 161ffe3c632Sopenharmony_ci * @type bool $weak 162ffe3c632Sopenharmony_ci * For Google-internal migration only. Do not use. 163ffe3c632Sopenharmony_ci * @type \Google\Protobuf\Internal\UninterpretedOption[]|\Google\Protobuf\Internal\RepeatedField $uninterpreted_option 164ffe3c632Sopenharmony_ci * The parser stores options it doesn't recognize here. See above. 165ffe3c632Sopenharmony_ci * } 166ffe3c632Sopenharmony_ci */ 167ffe3c632Sopenharmony_ci public function __construct($data = NULL) { 168ffe3c632Sopenharmony_ci \GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); 169ffe3c632Sopenharmony_ci parent::__construct($data); 170ffe3c632Sopenharmony_ci } 171ffe3c632Sopenharmony_ci 172ffe3c632Sopenharmony_ci /** 173ffe3c632Sopenharmony_ci * The ctype option instructs the C++ code generator to use a different 174ffe3c632Sopenharmony_ci * representation of the field than it normally would. See the specific 175ffe3c632Sopenharmony_ci * options below. This option is not yet implemented in the open source 176ffe3c632Sopenharmony_ci * release -- sorry, we'll try to include it in a future version! 177ffe3c632Sopenharmony_ci * 178ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional .google.protobuf.FieldOptions.CType ctype = 1 [default = STRING];</code> 179ffe3c632Sopenharmony_ci * @return int 180ffe3c632Sopenharmony_ci */ 181ffe3c632Sopenharmony_ci public function getCtype() 182ffe3c632Sopenharmony_ci { 183ffe3c632Sopenharmony_ci return isset($this->ctype) ? $this->ctype : 0; 184ffe3c632Sopenharmony_ci } 185ffe3c632Sopenharmony_ci 186ffe3c632Sopenharmony_ci public function hasCtype() 187ffe3c632Sopenharmony_ci { 188ffe3c632Sopenharmony_ci return isset($this->ctype); 189ffe3c632Sopenharmony_ci } 190ffe3c632Sopenharmony_ci 191ffe3c632Sopenharmony_ci public function clearCtype() 192ffe3c632Sopenharmony_ci { 193ffe3c632Sopenharmony_ci unset($this->ctype); 194ffe3c632Sopenharmony_ci } 195ffe3c632Sopenharmony_ci 196ffe3c632Sopenharmony_ci /** 197ffe3c632Sopenharmony_ci * The ctype option instructs the C++ code generator to use a different 198ffe3c632Sopenharmony_ci * representation of the field than it normally would. See the specific 199ffe3c632Sopenharmony_ci * options below. This option is not yet implemented in the open source 200ffe3c632Sopenharmony_ci * release -- sorry, we'll try to include it in a future version! 201ffe3c632Sopenharmony_ci * 202ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional .google.protobuf.FieldOptions.CType ctype = 1 [default = STRING];</code> 203ffe3c632Sopenharmony_ci * @param int $var 204ffe3c632Sopenharmony_ci * @return $this 205ffe3c632Sopenharmony_ci */ 206ffe3c632Sopenharmony_ci public function setCtype($var) 207ffe3c632Sopenharmony_ci { 208ffe3c632Sopenharmony_ci GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldOptions\CType::class); 209ffe3c632Sopenharmony_ci $this->ctype = $var; 210ffe3c632Sopenharmony_ci 211ffe3c632Sopenharmony_ci return $this; 212ffe3c632Sopenharmony_ci } 213ffe3c632Sopenharmony_ci 214ffe3c632Sopenharmony_ci /** 215ffe3c632Sopenharmony_ci * The packed option can be enabled for repeated primitive fields to enable 216ffe3c632Sopenharmony_ci * a more efficient representation on the wire. Rather than repeatedly 217ffe3c632Sopenharmony_ci * writing the tag and type for each element, the entire array is encoded as 218ffe3c632Sopenharmony_ci * a single length-delimited blob. In proto3, only explicit setting it to 219ffe3c632Sopenharmony_ci * false will avoid using packed encoding. 220ffe3c632Sopenharmony_ci * 221ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool packed = 2;</code> 222ffe3c632Sopenharmony_ci * @return bool 223ffe3c632Sopenharmony_ci */ 224ffe3c632Sopenharmony_ci public function getPacked() 225ffe3c632Sopenharmony_ci { 226ffe3c632Sopenharmony_ci return isset($this->packed) ? $this->packed : false; 227ffe3c632Sopenharmony_ci } 228ffe3c632Sopenharmony_ci 229ffe3c632Sopenharmony_ci public function hasPacked() 230ffe3c632Sopenharmony_ci { 231ffe3c632Sopenharmony_ci return isset($this->packed); 232ffe3c632Sopenharmony_ci } 233ffe3c632Sopenharmony_ci 234ffe3c632Sopenharmony_ci public function clearPacked() 235ffe3c632Sopenharmony_ci { 236ffe3c632Sopenharmony_ci unset($this->packed); 237ffe3c632Sopenharmony_ci } 238ffe3c632Sopenharmony_ci 239ffe3c632Sopenharmony_ci /** 240ffe3c632Sopenharmony_ci * The packed option can be enabled for repeated primitive fields to enable 241ffe3c632Sopenharmony_ci * a more efficient representation on the wire. Rather than repeatedly 242ffe3c632Sopenharmony_ci * writing the tag and type for each element, the entire array is encoded as 243ffe3c632Sopenharmony_ci * a single length-delimited blob. In proto3, only explicit setting it to 244ffe3c632Sopenharmony_ci * false will avoid using packed encoding. 245ffe3c632Sopenharmony_ci * 246ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool packed = 2;</code> 247ffe3c632Sopenharmony_ci * @param bool $var 248ffe3c632Sopenharmony_ci * @return $this 249ffe3c632Sopenharmony_ci */ 250ffe3c632Sopenharmony_ci public function setPacked($var) 251ffe3c632Sopenharmony_ci { 252ffe3c632Sopenharmony_ci GPBUtil::checkBool($var); 253ffe3c632Sopenharmony_ci $this->packed = $var; 254ffe3c632Sopenharmony_ci 255ffe3c632Sopenharmony_ci return $this; 256ffe3c632Sopenharmony_ci } 257ffe3c632Sopenharmony_ci 258ffe3c632Sopenharmony_ci /** 259ffe3c632Sopenharmony_ci * The jstype option determines the JavaScript type used for values of the 260ffe3c632Sopenharmony_ci * field. The option is permitted only for 64 bit integral and fixed types 261ffe3c632Sopenharmony_ci * (int64, uint64, sint64, fixed64, sfixed64). A field with jstype JS_STRING 262ffe3c632Sopenharmony_ci * is represented as JavaScript string, which avoids loss of precision that 263ffe3c632Sopenharmony_ci * can happen when a large value is converted to a floating point JavaScript. 264ffe3c632Sopenharmony_ci * Specifying JS_NUMBER for the jstype causes the generated JavaScript code to 265ffe3c632Sopenharmony_ci * use the JavaScript "number" type. The behavior of the default option 266ffe3c632Sopenharmony_ci * JS_NORMAL is implementation dependent. 267ffe3c632Sopenharmony_ci * This option is an enum to permit additional types to be added, e.g. 268ffe3c632Sopenharmony_ci * goog.math.Integer. 269ffe3c632Sopenharmony_ci * 270ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL];</code> 271ffe3c632Sopenharmony_ci * @return int 272ffe3c632Sopenharmony_ci */ 273ffe3c632Sopenharmony_ci public function getJstype() 274ffe3c632Sopenharmony_ci { 275ffe3c632Sopenharmony_ci return isset($this->jstype) ? $this->jstype : 0; 276ffe3c632Sopenharmony_ci } 277ffe3c632Sopenharmony_ci 278ffe3c632Sopenharmony_ci public function hasJstype() 279ffe3c632Sopenharmony_ci { 280ffe3c632Sopenharmony_ci return isset($this->jstype); 281ffe3c632Sopenharmony_ci } 282ffe3c632Sopenharmony_ci 283ffe3c632Sopenharmony_ci public function clearJstype() 284ffe3c632Sopenharmony_ci { 285ffe3c632Sopenharmony_ci unset($this->jstype); 286ffe3c632Sopenharmony_ci } 287ffe3c632Sopenharmony_ci 288ffe3c632Sopenharmony_ci /** 289ffe3c632Sopenharmony_ci * The jstype option determines the JavaScript type used for values of the 290ffe3c632Sopenharmony_ci * field. The option is permitted only for 64 bit integral and fixed types 291ffe3c632Sopenharmony_ci * (int64, uint64, sint64, fixed64, sfixed64). A field with jstype JS_STRING 292ffe3c632Sopenharmony_ci * is represented as JavaScript string, which avoids loss of precision that 293ffe3c632Sopenharmony_ci * can happen when a large value is converted to a floating point JavaScript. 294ffe3c632Sopenharmony_ci * Specifying JS_NUMBER for the jstype causes the generated JavaScript code to 295ffe3c632Sopenharmony_ci * use the JavaScript "number" type. The behavior of the default option 296ffe3c632Sopenharmony_ci * JS_NORMAL is implementation dependent. 297ffe3c632Sopenharmony_ci * This option is an enum to permit additional types to be added, e.g. 298ffe3c632Sopenharmony_ci * goog.math.Integer. 299ffe3c632Sopenharmony_ci * 300ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL];</code> 301ffe3c632Sopenharmony_ci * @param int $var 302ffe3c632Sopenharmony_ci * @return $this 303ffe3c632Sopenharmony_ci */ 304ffe3c632Sopenharmony_ci public function setJstype($var) 305ffe3c632Sopenharmony_ci { 306ffe3c632Sopenharmony_ci GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldOptions\JSType::class); 307ffe3c632Sopenharmony_ci $this->jstype = $var; 308ffe3c632Sopenharmony_ci 309ffe3c632Sopenharmony_ci return $this; 310ffe3c632Sopenharmony_ci } 311ffe3c632Sopenharmony_ci 312ffe3c632Sopenharmony_ci /** 313ffe3c632Sopenharmony_ci * Should this field be parsed lazily? Lazy applies only to message-type 314ffe3c632Sopenharmony_ci * fields. It means that when the outer message is initially parsed, the 315ffe3c632Sopenharmony_ci * inner message's contents will not be parsed but instead stored in encoded 316ffe3c632Sopenharmony_ci * form. The inner message will actually be parsed when it is first accessed. 317ffe3c632Sopenharmony_ci * This is only a hint. Implementations are free to choose whether to use 318ffe3c632Sopenharmony_ci * eager or lazy parsing regardless of the value of this option. However, 319ffe3c632Sopenharmony_ci * setting this option true suggests that the protocol author believes that 320ffe3c632Sopenharmony_ci * using lazy parsing on this field is worth the additional bookkeeping 321ffe3c632Sopenharmony_ci * overhead typically needed to implement it. 322ffe3c632Sopenharmony_ci * This option does not affect the public interface of any generated code; 323ffe3c632Sopenharmony_ci * all method signatures remain the same. Furthermore, thread-safety of the 324ffe3c632Sopenharmony_ci * interface is not affected by this option; const methods remain safe to 325ffe3c632Sopenharmony_ci * call from multiple threads concurrently, while non-const methods continue 326ffe3c632Sopenharmony_ci * to require exclusive access. 327ffe3c632Sopenharmony_ci * Note that implementations may choose not to check required fields within 328ffe3c632Sopenharmony_ci * a lazy sub-message. That is, calling IsInitialized() on the outer message 329ffe3c632Sopenharmony_ci * may return true even if the inner message has missing required fields. 330ffe3c632Sopenharmony_ci * This is necessary because otherwise the inner message would have to be 331ffe3c632Sopenharmony_ci * parsed in order to perform the check, defeating the purpose of lazy 332ffe3c632Sopenharmony_ci * parsing. An implementation which chooses not to check required fields 333ffe3c632Sopenharmony_ci * must be consistent about it. That is, for any particular sub-message, the 334ffe3c632Sopenharmony_ci * implementation must either *always* check its required fields, or *never* 335ffe3c632Sopenharmony_ci * check its required fields, regardless of whether or not the message has 336ffe3c632Sopenharmony_ci * been parsed. 337ffe3c632Sopenharmony_ci * 338ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool lazy = 5 [default = false];</code> 339ffe3c632Sopenharmony_ci * @return bool 340ffe3c632Sopenharmony_ci */ 341ffe3c632Sopenharmony_ci public function getLazy() 342ffe3c632Sopenharmony_ci { 343ffe3c632Sopenharmony_ci return isset($this->lazy) ? $this->lazy : false; 344ffe3c632Sopenharmony_ci } 345ffe3c632Sopenharmony_ci 346ffe3c632Sopenharmony_ci public function hasLazy() 347ffe3c632Sopenharmony_ci { 348ffe3c632Sopenharmony_ci return isset($this->lazy); 349ffe3c632Sopenharmony_ci } 350ffe3c632Sopenharmony_ci 351ffe3c632Sopenharmony_ci public function clearLazy() 352ffe3c632Sopenharmony_ci { 353ffe3c632Sopenharmony_ci unset($this->lazy); 354ffe3c632Sopenharmony_ci } 355ffe3c632Sopenharmony_ci 356ffe3c632Sopenharmony_ci /** 357ffe3c632Sopenharmony_ci * Should this field be parsed lazily? Lazy applies only to message-type 358ffe3c632Sopenharmony_ci * fields. It means that when the outer message is initially parsed, the 359ffe3c632Sopenharmony_ci * inner message's contents will not be parsed but instead stored in encoded 360ffe3c632Sopenharmony_ci * form. The inner message will actually be parsed when it is first accessed. 361ffe3c632Sopenharmony_ci * This is only a hint. Implementations are free to choose whether to use 362ffe3c632Sopenharmony_ci * eager or lazy parsing regardless of the value of this option. However, 363ffe3c632Sopenharmony_ci * setting this option true suggests that the protocol author believes that 364ffe3c632Sopenharmony_ci * using lazy parsing on this field is worth the additional bookkeeping 365ffe3c632Sopenharmony_ci * overhead typically needed to implement it. 366ffe3c632Sopenharmony_ci * This option does not affect the public interface of any generated code; 367ffe3c632Sopenharmony_ci * all method signatures remain the same. Furthermore, thread-safety of the 368ffe3c632Sopenharmony_ci * interface is not affected by this option; const methods remain safe to 369ffe3c632Sopenharmony_ci * call from multiple threads concurrently, while non-const methods continue 370ffe3c632Sopenharmony_ci * to require exclusive access. 371ffe3c632Sopenharmony_ci * Note that implementations may choose not to check required fields within 372ffe3c632Sopenharmony_ci * a lazy sub-message. That is, calling IsInitialized() on the outer message 373ffe3c632Sopenharmony_ci * may return true even if the inner message has missing required fields. 374ffe3c632Sopenharmony_ci * This is necessary because otherwise the inner message would have to be 375ffe3c632Sopenharmony_ci * parsed in order to perform the check, defeating the purpose of lazy 376ffe3c632Sopenharmony_ci * parsing. An implementation which chooses not to check required fields 377ffe3c632Sopenharmony_ci * must be consistent about it. That is, for any particular sub-message, the 378ffe3c632Sopenharmony_ci * implementation must either *always* check its required fields, or *never* 379ffe3c632Sopenharmony_ci * check its required fields, regardless of whether or not the message has 380ffe3c632Sopenharmony_ci * been parsed. 381ffe3c632Sopenharmony_ci * 382ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool lazy = 5 [default = false];</code> 383ffe3c632Sopenharmony_ci * @param bool $var 384ffe3c632Sopenharmony_ci * @return $this 385ffe3c632Sopenharmony_ci */ 386ffe3c632Sopenharmony_ci public function setLazy($var) 387ffe3c632Sopenharmony_ci { 388ffe3c632Sopenharmony_ci GPBUtil::checkBool($var); 389ffe3c632Sopenharmony_ci $this->lazy = $var; 390ffe3c632Sopenharmony_ci 391ffe3c632Sopenharmony_ci return $this; 392ffe3c632Sopenharmony_ci } 393ffe3c632Sopenharmony_ci 394ffe3c632Sopenharmony_ci /** 395ffe3c632Sopenharmony_ci * Is this field deprecated? 396ffe3c632Sopenharmony_ci * Depending on the target platform, this can emit Deprecated annotations 397ffe3c632Sopenharmony_ci * for accessors, or it will be completely ignored; in the very least, this 398ffe3c632Sopenharmony_ci * is a formalization for deprecating fields. 399ffe3c632Sopenharmony_ci * 400ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool deprecated = 3 [default = false];</code> 401ffe3c632Sopenharmony_ci * @return bool 402ffe3c632Sopenharmony_ci */ 403ffe3c632Sopenharmony_ci public function getDeprecated() 404ffe3c632Sopenharmony_ci { 405ffe3c632Sopenharmony_ci return isset($this->deprecated) ? $this->deprecated : false; 406ffe3c632Sopenharmony_ci } 407ffe3c632Sopenharmony_ci 408ffe3c632Sopenharmony_ci public function hasDeprecated() 409ffe3c632Sopenharmony_ci { 410ffe3c632Sopenharmony_ci return isset($this->deprecated); 411ffe3c632Sopenharmony_ci } 412ffe3c632Sopenharmony_ci 413ffe3c632Sopenharmony_ci public function clearDeprecated() 414ffe3c632Sopenharmony_ci { 415ffe3c632Sopenharmony_ci unset($this->deprecated); 416ffe3c632Sopenharmony_ci } 417ffe3c632Sopenharmony_ci 418ffe3c632Sopenharmony_ci /** 419ffe3c632Sopenharmony_ci * Is this field deprecated? 420ffe3c632Sopenharmony_ci * Depending on the target platform, this can emit Deprecated annotations 421ffe3c632Sopenharmony_ci * for accessors, or it will be completely ignored; in the very least, this 422ffe3c632Sopenharmony_ci * is a formalization for deprecating fields. 423ffe3c632Sopenharmony_ci * 424ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool deprecated = 3 [default = false];</code> 425ffe3c632Sopenharmony_ci * @param bool $var 426ffe3c632Sopenharmony_ci * @return $this 427ffe3c632Sopenharmony_ci */ 428ffe3c632Sopenharmony_ci public function setDeprecated($var) 429ffe3c632Sopenharmony_ci { 430ffe3c632Sopenharmony_ci GPBUtil::checkBool($var); 431ffe3c632Sopenharmony_ci $this->deprecated = $var; 432ffe3c632Sopenharmony_ci 433ffe3c632Sopenharmony_ci return $this; 434ffe3c632Sopenharmony_ci } 435ffe3c632Sopenharmony_ci 436ffe3c632Sopenharmony_ci /** 437ffe3c632Sopenharmony_ci * For Google-internal migration only. Do not use. 438ffe3c632Sopenharmony_ci * 439ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool weak = 10 [default = false];</code> 440ffe3c632Sopenharmony_ci * @return bool 441ffe3c632Sopenharmony_ci */ 442ffe3c632Sopenharmony_ci public function getWeak() 443ffe3c632Sopenharmony_ci { 444ffe3c632Sopenharmony_ci return isset($this->weak) ? $this->weak : false; 445ffe3c632Sopenharmony_ci } 446ffe3c632Sopenharmony_ci 447ffe3c632Sopenharmony_ci public function hasWeak() 448ffe3c632Sopenharmony_ci { 449ffe3c632Sopenharmony_ci return isset($this->weak); 450ffe3c632Sopenharmony_ci } 451ffe3c632Sopenharmony_ci 452ffe3c632Sopenharmony_ci public function clearWeak() 453ffe3c632Sopenharmony_ci { 454ffe3c632Sopenharmony_ci unset($this->weak); 455ffe3c632Sopenharmony_ci } 456ffe3c632Sopenharmony_ci 457ffe3c632Sopenharmony_ci /** 458ffe3c632Sopenharmony_ci * For Google-internal migration only. Do not use. 459ffe3c632Sopenharmony_ci * 460ffe3c632Sopenharmony_ci * Generated from protobuf field <code>optional bool weak = 10 [default = false];</code> 461ffe3c632Sopenharmony_ci * @param bool $var 462ffe3c632Sopenharmony_ci * @return $this 463ffe3c632Sopenharmony_ci */ 464ffe3c632Sopenharmony_ci public function setWeak($var) 465ffe3c632Sopenharmony_ci { 466ffe3c632Sopenharmony_ci GPBUtil::checkBool($var); 467ffe3c632Sopenharmony_ci $this->weak = $var; 468ffe3c632Sopenharmony_ci 469ffe3c632Sopenharmony_ci return $this; 470ffe3c632Sopenharmony_ci } 471ffe3c632Sopenharmony_ci 472ffe3c632Sopenharmony_ci /** 473ffe3c632Sopenharmony_ci * The parser stores options it doesn't recognize here. See above. 474ffe3c632Sopenharmony_ci * 475ffe3c632Sopenharmony_ci * Generated from protobuf field <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> 476ffe3c632Sopenharmony_ci * @return \Google\Protobuf\Internal\RepeatedField 477ffe3c632Sopenharmony_ci */ 478ffe3c632Sopenharmony_ci public function getUninterpretedOption() 479ffe3c632Sopenharmony_ci { 480ffe3c632Sopenharmony_ci return $this->uninterpreted_option; 481ffe3c632Sopenharmony_ci } 482ffe3c632Sopenharmony_ci 483ffe3c632Sopenharmony_ci /** 484ffe3c632Sopenharmony_ci * The parser stores options it doesn't recognize here. See above. 485ffe3c632Sopenharmony_ci * 486ffe3c632Sopenharmony_ci * Generated from protobuf field <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> 487ffe3c632Sopenharmony_ci * @param \Google\Protobuf\Internal\UninterpretedOption[]|\Google\Protobuf\Internal\RepeatedField $var 488ffe3c632Sopenharmony_ci * @return $this 489ffe3c632Sopenharmony_ci */ 490ffe3c632Sopenharmony_ci public function setUninterpretedOption($var) 491ffe3c632Sopenharmony_ci { 492ffe3c632Sopenharmony_ci $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); 493ffe3c632Sopenharmony_ci $this->uninterpreted_option = $arr; 494ffe3c632Sopenharmony_ci 495ffe3c632Sopenharmony_ci return $this; 496ffe3c632Sopenharmony_ci } 497ffe3c632Sopenharmony_ci 498ffe3c632Sopenharmony_ci} 499ffe3c632Sopenharmony_ci 500