WriteStatistics.php 8.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256
  1. <?php
  2. # Generated by the protocol buffer compiler. DO NOT EDIT!
  3. # source: protos/ydb_topic.proto
  4. namespace Ydb\Topic\StreamWriteMessage\WriteResponse;
  5. use Google\Protobuf\Internal\GPBType;
  6. use Google\Protobuf\Internal\RepeatedField;
  7. use Google\Protobuf\Internal\GPBUtil;
  8. /**
  9. * Message with write statistics.
  10. *
  11. * Generated from protobuf message <code>Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics</code>
  12. */
  13. class WriteStatistics extends \Google\Protobuf\Internal\Message
  14. {
  15. /**
  16. * Time spent in persisting of data. Same for each message in response.
  17. *
  18. * Generated from protobuf field <code>.google.protobuf.Duration persisting_time = 1;</code>
  19. */
  20. protected $persisting_time = null;
  21. /**
  22. * Time spent in queue before persisting, minimal of all messages in response.
  23. *
  24. * Generated from protobuf field <code>.google.protobuf.Duration min_queue_wait_time = 2;</code>
  25. */
  26. protected $min_queue_wait_time = null;
  27. /**
  28. * Time spent in queue before persisting, maximal of all messages in response.
  29. *
  30. * Generated from protobuf field <code>.google.protobuf.Duration max_queue_wait_time = 3;</code>
  31. */
  32. protected $max_queue_wait_time = null;
  33. /**
  34. * Time spent awaiting for partition write quota. Same for each message in response.
  35. *
  36. * Generated from protobuf field <code>.google.protobuf.Duration partition_quota_wait_time = 4;</code>
  37. */
  38. protected $partition_quota_wait_time = null;
  39. /**
  40. * Time spent awaiting for topic write quota. Same for each message in response.
  41. *
  42. * Generated from protobuf field <code>.google.protobuf.Duration topic_quota_wait_time = 5;</code>
  43. */
  44. protected $topic_quota_wait_time = null;
  45. /**
  46. * Constructor.
  47. *
  48. * @param array $data {
  49. * Optional. Data for populating the Message object.
  50. *
  51. * @type \Google\Protobuf\Duration $persisting_time
  52. * Time spent in persisting of data. Same for each message in response.
  53. * @type \Google\Protobuf\Duration $min_queue_wait_time
  54. * Time spent in queue before persisting, minimal of all messages in response.
  55. * @type \Google\Protobuf\Duration $max_queue_wait_time
  56. * Time spent in queue before persisting, maximal of all messages in response.
  57. * @type \Google\Protobuf\Duration $partition_quota_wait_time
  58. * Time spent awaiting for partition write quota. Same for each message in response.
  59. * @type \Google\Protobuf\Duration $topic_quota_wait_time
  60. * Time spent awaiting for topic write quota. Same for each message in response.
  61. * }
  62. */
  63. public function __construct($data = NULL) {
  64. \GPBMetadata\Protos\YdbTopic::initOnce();
  65. parent::__construct($data);
  66. }
  67. /**
  68. * Time spent in persisting of data. Same for each message in response.
  69. *
  70. * Generated from protobuf field <code>.google.protobuf.Duration persisting_time = 1;</code>
  71. * @return \Google\Protobuf\Duration|null
  72. */
  73. public function getPersistingTime()
  74. {
  75. return $this->persisting_time;
  76. }
  77. public function hasPersistingTime()
  78. {
  79. return isset($this->persisting_time);
  80. }
  81. public function clearPersistingTime()
  82. {
  83. unset($this->persisting_time);
  84. }
  85. /**
  86. * Time spent in persisting of data. Same for each message in response.
  87. *
  88. * Generated from protobuf field <code>.google.protobuf.Duration persisting_time = 1;</code>
  89. * @param \Google\Protobuf\Duration $var
  90. * @return $this
  91. */
  92. public function setPersistingTime($var)
  93. {
  94. GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
  95. $this->persisting_time = $var;
  96. return $this;
  97. }
  98. /**
  99. * Time spent in queue before persisting, minimal of all messages in response.
  100. *
  101. * Generated from protobuf field <code>.google.protobuf.Duration min_queue_wait_time = 2;</code>
  102. * @return \Google\Protobuf\Duration|null
  103. */
  104. public function getMinQueueWaitTime()
  105. {
  106. return $this->min_queue_wait_time;
  107. }
  108. public function hasMinQueueWaitTime()
  109. {
  110. return isset($this->min_queue_wait_time);
  111. }
  112. public function clearMinQueueWaitTime()
  113. {
  114. unset($this->min_queue_wait_time);
  115. }
  116. /**
  117. * Time spent in queue before persisting, minimal of all messages in response.
  118. *
  119. * Generated from protobuf field <code>.google.protobuf.Duration min_queue_wait_time = 2;</code>
  120. * @param \Google\Protobuf\Duration $var
  121. * @return $this
  122. */
  123. public function setMinQueueWaitTime($var)
  124. {
  125. GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
  126. $this->min_queue_wait_time = $var;
  127. return $this;
  128. }
  129. /**
  130. * Time spent in queue before persisting, maximal of all messages in response.
  131. *
  132. * Generated from protobuf field <code>.google.protobuf.Duration max_queue_wait_time = 3;</code>
  133. * @return \Google\Protobuf\Duration|null
  134. */
  135. public function getMaxQueueWaitTime()
  136. {
  137. return $this->max_queue_wait_time;
  138. }
  139. public function hasMaxQueueWaitTime()
  140. {
  141. return isset($this->max_queue_wait_time);
  142. }
  143. public function clearMaxQueueWaitTime()
  144. {
  145. unset($this->max_queue_wait_time);
  146. }
  147. /**
  148. * Time spent in queue before persisting, maximal of all messages in response.
  149. *
  150. * Generated from protobuf field <code>.google.protobuf.Duration max_queue_wait_time = 3;</code>
  151. * @param \Google\Protobuf\Duration $var
  152. * @return $this
  153. */
  154. public function setMaxQueueWaitTime($var)
  155. {
  156. GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
  157. $this->max_queue_wait_time = $var;
  158. return $this;
  159. }
  160. /**
  161. * Time spent awaiting for partition write quota. Same for each message in response.
  162. *
  163. * Generated from protobuf field <code>.google.protobuf.Duration partition_quota_wait_time = 4;</code>
  164. * @return \Google\Protobuf\Duration|null
  165. */
  166. public function getPartitionQuotaWaitTime()
  167. {
  168. return $this->partition_quota_wait_time;
  169. }
  170. public function hasPartitionQuotaWaitTime()
  171. {
  172. return isset($this->partition_quota_wait_time);
  173. }
  174. public function clearPartitionQuotaWaitTime()
  175. {
  176. unset($this->partition_quota_wait_time);
  177. }
  178. /**
  179. * Time spent awaiting for partition write quota. Same for each message in response.
  180. *
  181. * Generated from protobuf field <code>.google.protobuf.Duration partition_quota_wait_time = 4;</code>
  182. * @param \Google\Protobuf\Duration $var
  183. * @return $this
  184. */
  185. public function setPartitionQuotaWaitTime($var)
  186. {
  187. GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
  188. $this->partition_quota_wait_time = $var;
  189. return $this;
  190. }
  191. /**
  192. * Time spent awaiting for topic write quota. Same for each message in response.
  193. *
  194. * Generated from protobuf field <code>.google.protobuf.Duration topic_quota_wait_time = 5;</code>
  195. * @return \Google\Protobuf\Duration|null
  196. */
  197. public function getTopicQuotaWaitTime()
  198. {
  199. return $this->topic_quota_wait_time;
  200. }
  201. public function hasTopicQuotaWaitTime()
  202. {
  203. return isset($this->topic_quota_wait_time);
  204. }
  205. public function clearTopicQuotaWaitTime()
  206. {
  207. unset($this->topic_quota_wait_time);
  208. }
  209. /**
  210. * Time spent awaiting for topic write quota. Same for each message in response.
  211. *
  212. * Generated from protobuf field <code>.google.protobuf.Duration topic_quota_wait_time = 5;</code>
  213. * @param \Google\Protobuf\Duration $var
  214. * @return $this
  215. */
  216. public function setTopicQuotaWaitTime($var)
  217. {
  218. GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
  219. $this->topic_quota_wait_time = $var;
  220. return $this;
  221. }
  222. }
  223. // Adding a class alias for backwards compatibility with the previous class name.
  224. class_alias(WriteStatistics::class, \Ydb\Topic\StreamWriteMessage_WriteResponse_WriteStatistics::class);