SearchResponse.php 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. <?php
  2. # Generated by the protocol buffer compiler. DO NOT EDIT!
  3. # source: tulip.proto
  4. namespace Mint\Tulip\V1;
  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>mint.tulip.v1.SearchResponse</code>
  10. */
  11. class SearchResponse extends \Google\Protobuf\Internal\Message
  12. {
  13. /**
  14. * Generated from protobuf field <code>repeated .mint.tulip.v1.SearchResponse.Item items = 1;</code>
  15. */
  16. private $items;
  17. /**
  18. * Generated from protobuf field <code>.mint.tulip.v1.SearchRequest.Page page = 98;</code>
  19. */
  20. protected $page = null;
  21. /**
  22. * Generated from protobuf field <code>int32 total = 99;</code>
  23. */
  24. protected $total = 0;
  25. /**
  26. * Constructor.
  27. *
  28. * @param array $data {
  29. * Optional. Data for populating the Message object.
  30. *
  31. * @type array<\Mint\Tulip\V1\SearchResponse\Item>|\Google\Protobuf\Internal\RepeatedField $items
  32. * @type \Mint\Tulip\V1\SearchRequest\Page $page
  33. * @type int $total
  34. * }
  35. */
  36. public function __construct($data = NULL) {
  37. \GPBMetadata\Tulip::initOnce();
  38. parent::__construct($data);
  39. }
  40. /**
  41. * Generated from protobuf field <code>repeated .mint.tulip.v1.SearchResponse.Item items = 1;</code>
  42. * @return \Google\Protobuf\Internal\RepeatedField
  43. */
  44. public function getItems()
  45. {
  46. return $this->items;
  47. }
  48. /**
  49. * Generated from protobuf field <code>repeated .mint.tulip.v1.SearchResponse.Item items = 1;</code>
  50. * @param array<\Mint\Tulip\V1\SearchResponse\Item>|\Google\Protobuf\Internal\RepeatedField $var
  51. * @return $this
  52. */
  53. public function setItems($var)
  54. {
  55. $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Mint\Tulip\V1\SearchResponse\Item::class);
  56. $this->items = $arr;
  57. return $this;
  58. }
  59. /**
  60. * Generated from protobuf field <code>.mint.tulip.v1.SearchRequest.Page page = 98;</code>
  61. * @return \Mint\Tulip\V1\SearchRequest\Page|null
  62. */
  63. public function getPage()
  64. {
  65. return $this->page;
  66. }
  67. public function hasPage()
  68. {
  69. return isset($this->page);
  70. }
  71. public function clearPage()
  72. {
  73. unset($this->page);
  74. }
  75. /**
  76. * Generated from protobuf field <code>.mint.tulip.v1.SearchRequest.Page page = 98;</code>
  77. * @param \Mint\Tulip\V1\SearchRequest\Page $var
  78. * @return $this
  79. */
  80. public function setPage($var)
  81. {
  82. GPBUtil::checkMessage($var, \Mint\Tulip\V1\SearchRequest\Page::class);
  83. $this->page = $var;
  84. return $this;
  85. }
  86. /**
  87. * Generated from protobuf field <code>int32 total = 99;</code>
  88. * @return int
  89. */
  90. public function getTotal()
  91. {
  92. return $this->total;
  93. }
  94. /**
  95. * Generated from protobuf field <code>int32 total = 99;</code>
  96. * @param int $var
  97. * @return $this
  98. */
  99. public function setTotal($var)
  100. {
  101. GPBUtil::checkInt32($var);
  102. $this->total = $var;
  103. return $this;
  104. }
  105. }