KeyRange.php 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181
  1. <?php
  2. # Generated by the protocol buffer compiler. DO NOT EDIT!
  3. # source: protos/ydb_table.proto
  4. namespace Ydb\Table;
  5. use Google\Protobuf\Internal\GPBType;
  6. use Google\Protobuf\Internal\RepeatedField;
  7. use Google\Protobuf\Internal\GPBUtil;
  8. /**
  9. * Generated from protobuf message <code>Ydb.Table.KeyRange</code>
  10. */
  11. class KeyRange extends \Google\Protobuf\Internal\Message
  12. {
  13. protected $from_bound;
  14. protected $to_bound;
  15. /**
  16. * Constructor.
  17. *
  18. * @param array $data {
  19. * Optional. Data for populating the Message object.
  20. *
  21. * @type \Ydb\TypedValue $greater
  22. * Specify if we don't want to include given key
  23. * @type \Ydb\TypedValue $greater_or_equal
  24. * Specify if we want to include given key
  25. * @type \Ydb\TypedValue $less
  26. * Specify if we don't want to include given key
  27. * @type \Ydb\TypedValue $less_or_equal
  28. * Specify if we want to include given key
  29. * }
  30. */
  31. public function __construct($data = NULL) {
  32. \GPBMetadata\Protos\YdbTable::initOnce();
  33. parent::__construct($data);
  34. }
  35. /**
  36. * Specify if we don't want to include given key
  37. *
  38. * Generated from protobuf field <code>.Ydb.TypedValue greater = 1;</code>
  39. * @return \Ydb\TypedValue|null
  40. */
  41. public function getGreater()
  42. {
  43. return $this->readOneof(1);
  44. }
  45. public function hasGreater()
  46. {
  47. return $this->hasOneof(1);
  48. }
  49. /**
  50. * Specify if we don't want to include given key
  51. *
  52. * Generated from protobuf field <code>.Ydb.TypedValue greater = 1;</code>
  53. * @param \Ydb\TypedValue $var
  54. * @return $this
  55. */
  56. public function setGreater($var)
  57. {
  58. GPBUtil::checkMessage($var, \Ydb\TypedValue::class);
  59. $this->writeOneof(1, $var);
  60. return $this;
  61. }
  62. /**
  63. * Specify if we want to include given key
  64. *
  65. * Generated from protobuf field <code>.Ydb.TypedValue greater_or_equal = 2;</code>
  66. * @return \Ydb\TypedValue|null
  67. */
  68. public function getGreaterOrEqual()
  69. {
  70. return $this->readOneof(2);
  71. }
  72. public function hasGreaterOrEqual()
  73. {
  74. return $this->hasOneof(2);
  75. }
  76. /**
  77. * Specify if we want to include given key
  78. *
  79. * Generated from protobuf field <code>.Ydb.TypedValue greater_or_equal = 2;</code>
  80. * @param \Ydb\TypedValue $var
  81. * @return $this
  82. */
  83. public function setGreaterOrEqual($var)
  84. {
  85. GPBUtil::checkMessage($var, \Ydb\TypedValue::class);
  86. $this->writeOneof(2, $var);
  87. return $this;
  88. }
  89. /**
  90. * Specify if we don't want to include given key
  91. *
  92. * Generated from protobuf field <code>.Ydb.TypedValue less = 3;</code>
  93. * @return \Ydb\TypedValue|null
  94. */
  95. public function getLess()
  96. {
  97. return $this->readOneof(3);
  98. }
  99. public function hasLess()
  100. {
  101. return $this->hasOneof(3);
  102. }
  103. /**
  104. * Specify if we don't want to include given key
  105. *
  106. * Generated from protobuf field <code>.Ydb.TypedValue less = 3;</code>
  107. * @param \Ydb\TypedValue $var
  108. * @return $this
  109. */
  110. public function setLess($var)
  111. {
  112. GPBUtil::checkMessage($var, \Ydb\TypedValue::class);
  113. $this->writeOneof(3, $var);
  114. return $this;
  115. }
  116. /**
  117. * Specify if we want to include given key
  118. *
  119. * Generated from protobuf field <code>.Ydb.TypedValue less_or_equal = 4;</code>
  120. * @return \Ydb\TypedValue|null
  121. */
  122. public function getLessOrEqual()
  123. {
  124. return $this->readOneof(4);
  125. }
  126. public function hasLessOrEqual()
  127. {
  128. return $this->hasOneof(4);
  129. }
  130. /**
  131. * Specify if we want to include given key
  132. *
  133. * Generated from protobuf field <code>.Ydb.TypedValue less_or_equal = 4;</code>
  134. * @param \Ydb\TypedValue $var
  135. * @return $this
  136. */
  137. public function setLessOrEqual($var)
  138. {
  139. GPBUtil::checkMessage($var, \Ydb\TypedValue::class);
  140. $this->writeOneof(4, $var);
  141. return $this;
  142. }
  143. /**
  144. * @return string
  145. */
  146. public function getFromBound()
  147. {
  148. return $this->whichOneof("from_bound");
  149. }
  150. /**
  151. * @return string
  152. */
  153. public function getToBound()
  154. {
  155. return $this->whichOneof("to_bound");
  156. }
  157. }