UninterpretedOption.php 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273
  1. <?php
  2. # Generated by the protocol buffer compiler. DO NOT EDIT!
  3. # source: google/protobuf/descriptor.proto
  4. namespace Google\Protobuf\Internal;
  5. use Google\Protobuf\Internal\GPBType;
  6. use Google\Protobuf\Internal\GPBWire;
  7. use Google\Protobuf\Internal\RepeatedField;
  8. use Google\Protobuf\Internal\InputStream;
  9. use Google\Protobuf\Internal\GPBUtil;
  10. /**
  11. * A message representing a option the parser does not recognize. This only
  12. * appears in options protos created by the compiler::Parser class.
  13. * DescriptorPool resolves these when building Descriptor objects. Therefore,
  14. * options protos in descriptor objects (e.g. returned by Descriptor::options(),
  15. * or produced by Descriptor::CopyTo()) will never have UninterpretedOptions
  16. * in them.
  17. *
  18. * Generated from protobuf message <code>google.protobuf.UninterpretedOption</code>
  19. */
  20. class UninterpretedOption extends \Google\Protobuf\Internal\Message
  21. {
  22. /**
  23. * Generated from protobuf field <code>repeated .google.protobuf.UninterpretedOption.NamePart name = 2;</code>
  24. */
  25. private $name;
  26. private $has_name = false;
  27. /**
  28. * The value of the uninterpreted option, in whatever type the tokenizer
  29. * identified it as during parsing. Exactly one of these should be set.
  30. *
  31. * Generated from protobuf field <code>optional string identifier_value = 3;</code>
  32. */
  33. private $identifier_value = '';
  34. private $has_identifier_value = false;
  35. /**
  36. * Generated from protobuf field <code>optional uint64 positive_int_value = 4;</code>
  37. */
  38. private $positive_int_value = 0;
  39. private $has_positive_int_value = false;
  40. /**
  41. * Generated from protobuf field <code>optional int64 negative_int_value = 5;</code>
  42. */
  43. private $negative_int_value = 0;
  44. private $has_negative_int_value = false;
  45. /**
  46. * Generated from protobuf field <code>optional double double_value = 6;</code>
  47. */
  48. private $double_value = 0.0;
  49. private $has_double_value = false;
  50. /**
  51. * Generated from protobuf field <code>optional bytes string_value = 7;</code>
  52. */
  53. private $string_value = '';
  54. private $has_string_value = false;
  55. /**
  56. * Generated from protobuf field <code>optional string aggregate_value = 8;</code>
  57. */
  58. private $aggregate_value = '';
  59. private $has_aggregate_value = false;
  60. public function __construct() {
  61. \GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce();
  62. parent::__construct();
  63. }
  64. /**
  65. * Generated from protobuf field <code>repeated .google.protobuf.UninterpretedOption.NamePart name = 2;</code>
  66. * @return \Google\Protobuf\Internal\RepeatedField
  67. */
  68. public function getName()
  69. {
  70. return $this->name;
  71. }
  72. /**
  73. * Generated from protobuf field <code>repeated .google.protobuf.UninterpretedOption.NamePart name = 2;</code>
  74. * @param \Google\Protobuf\Internal\UninterpretedOption_NamePart[]|\Google\Protobuf\Internal\RepeatedField $var
  75. * @return $this
  76. */
  77. public function setName($var)
  78. {
  79. $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption_NamePart::class);
  80. $this->name = $arr;
  81. $this->has_name = true;
  82. return $this;
  83. }
  84. public function hasName()
  85. {
  86. return $this->has_name;
  87. }
  88. /**
  89. * The value of the uninterpreted option, in whatever type the tokenizer
  90. * identified it as during parsing. Exactly one of these should be set.
  91. *
  92. * Generated from protobuf field <code>optional string identifier_value = 3;</code>
  93. * @return string
  94. */
  95. public function getIdentifierValue()
  96. {
  97. return $this->identifier_value;
  98. }
  99. /**
  100. * The value of the uninterpreted option, in whatever type the tokenizer
  101. * identified it as during parsing. Exactly one of these should be set.
  102. *
  103. * Generated from protobuf field <code>optional string identifier_value = 3;</code>
  104. * @param string $var
  105. * @return $this
  106. */
  107. public function setIdentifierValue($var)
  108. {
  109. GPBUtil::checkString($var, True);
  110. $this->identifier_value = $var;
  111. $this->has_identifier_value = true;
  112. return $this;
  113. }
  114. public function hasIdentifierValue()
  115. {
  116. return $this->has_identifier_value;
  117. }
  118. /**
  119. * Generated from protobuf field <code>optional uint64 positive_int_value = 4;</code>
  120. * @return int|string
  121. */
  122. public function getPositiveIntValue()
  123. {
  124. return $this->positive_int_value;
  125. }
  126. /**
  127. * Generated from protobuf field <code>optional uint64 positive_int_value = 4;</code>
  128. * @param int|string $var
  129. * @return $this
  130. */
  131. public function setPositiveIntValue($var)
  132. {
  133. GPBUtil::checkUint64($var);
  134. $this->positive_int_value = $var;
  135. $this->has_positive_int_value = true;
  136. return $this;
  137. }
  138. public function hasPositiveIntValue()
  139. {
  140. return $this->has_positive_int_value;
  141. }
  142. /**
  143. * Generated from protobuf field <code>optional int64 negative_int_value = 5;</code>
  144. * @return int|string
  145. */
  146. public function getNegativeIntValue()
  147. {
  148. return $this->negative_int_value;
  149. }
  150. /**
  151. * Generated from protobuf field <code>optional int64 negative_int_value = 5;</code>
  152. * @param int|string $var
  153. * @return $this
  154. */
  155. public function setNegativeIntValue($var)
  156. {
  157. GPBUtil::checkInt64($var);
  158. $this->negative_int_value = $var;
  159. $this->has_negative_int_value = true;
  160. return $this;
  161. }
  162. public function hasNegativeIntValue()
  163. {
  164. return $this->has_negative_int_value;
  165. }
  166. /**
  167. * Generated from protobuf field <code>optional double double_value = 6;</code>
  168. * @return float
  169. */
  170. public function getDoubleValue()
  171. {
  172. return $this->double_value;
  173. }
  174. /**
  175. * Generated from protobuf field <code>optional double double_value = 6;</code>
  176. * @param float $var
  177. * @return $this
  178. */
  179. public function setDoubleValue($var)
  180. {
  181. GPBUtil::checkDouble($var);
  182. $this->double_value = $var;
  183. $this->has_double_value = true;
  184. return $this;
  185. }
  186. public function hasDoubleValue()
  187. {
  188. return $this->has_double_value;
  189. }
  190. /**
  191. * Generated from protobuf field <code>optional bytes string_value = 7;</code>
  192. * @return string
  193. */
  194. public function getStringValue()
  195. {
  196. return $this->string_value;
  197. }
  198. /**
  199. * Generated from protobuf field <code>optional bytes string_value = 7;</code>
  200. * @param string $var
  201. * @return $this
  202. */
  203. public function setStringValue($var)
  204. {
  205. GPBUtil::checkString($var, False);
  206. $this->string_value = $var;
  207. $this->has_string_value = true;
  208. return $this;
  209. }
  210. public function hasStringValue()
  211. {
  212. return $this->has_string_value;
  213. }
  214. /**
  215. * Generated from protobuf field <code>optional string aggregate_value = 8;</code>
  216. * @return string
  217. */
  218. public function getAggregateValue()
  219. {
  220. return $this->aggregate_value;
  221. }
  222. /**
  223. * Generated from protobuf field <code>optional string aggregate_value = 8;</code>
  224. * @param string $var
  225. * @return $this
  226. */
  227. public function setAggregateValue($var)
  228. {
  229. GPBUtil::checkString($var, True);
  230. $this->aggregate_value = $var;
  231. $this->has_aggregate_value = true;
  232. return $this;
  233. }
  234. public function hasAggregateValue()
  235. {
  236. return $this->has_aggregate_value;
  237. }
  238. }