/
githubmirror
/
ydb-php-sdk
Обзор
Документация
Войти
/
githubmirror
/
ydb-php-sdk
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
protos/Ydb/Topic/StreamWriteMessage/WriteResponse.php
156 строк
5 KB
Alexei Shabalin
updated protos
17 фев 2023, 13:31
17 фев 2023, 13:31
ae6a264
Код
Авторство
О чём код?
<?php # Generated by the protocol buffer compiler. DO NOT EDIT! # source: protos/ydb_topic.proto namespace Ydb\Topic\StreamWriteMessage; use Google\Protobuf\Internal\GPBType; use Google\Protobuf\Internal\RepeatedField; use Google\Protobuf\Internal\GPBUtil; /** * Message that represents acknowledgment for sequence of client messages. * This sequence is persisted together so write statistics is for messages batch. * * Generated from protobuf message <code>Ydb.Topic.StreamWriteMessage.WriteResponse</code> */ class WriteResponse extends \Google\Protobuf\Internal\Message { /** * Number of acks is equal to number of messages in the corresponding WriteRequests. * * Generated from protobuf field <code>repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;</code> */ private $acks; /** * Assigned partition for all client messages inside this batch. * This actual partition may differ from that returned in InitResponse * or other WriteResponses in this write session. * * Generated from protobuf field <code>int64 partition_id = 2;</code> */ protected $partition_id = 0; /** * Write statistics for this sequence of client messages. * * Generated from protobuf field <code>.Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;</code> */ protected $write_statistics = null; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type array<\Ydb\Topic\StreamWriteMessage\WriteResponse\WriteAck>|\Google\Protobuf\Internal\RepeatedField $acks * Number of acks is equal to number of messages in the corresponding WriteRequests. * @type int|string $partition_id * Assigned partition for all client messages inside this batch. * This actual partition may differ from that returned in InitResponse * or other WriteResponses in this write session. * @type \Ydb\Topic\StreamWriteMessage\WriteResponse\WriteStatistics $write_statistics * Write statistics for this sequence of client messages. * } */ public function __construct($data = NULL) { \GPBMetadata\Protos\YdbTopic::initOnce(); parent::__construct($data); } /** * Number of acks is equal to number of messages in the corresponding WriteRequests. * * Generated from protobuf field <code>repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;</code> * @return \Google\Protobuf\Internal\RepeatedField */ public function getAcks() { return $this->acks; } /** * Number of acks is equal to number of messages in the corresponding WriteRequests. * * Generated from protobuf field <code>repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;</code> * @param array<\Ydb\Topic\StreamWriteMessage\WriteResponse\WriteAck>|\Google\Protobuf\Internal\RepeatedField $var * @return $this */ public function setAcks($var) { $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Ydb\Topic\StreamWriteMessage\WriteResponse\WriteAck::class); $this->acks = $arr; return $this; } /** * Assigned partition for all client messages inside this batch. * This actual partition may differ from that returned in InitResponse * or other WriteResponses in this write session. * * Generated from protobuf field <code>int64 partition_id = 2;</code> * @return int|string */ public function getPartitionId() { return $this->partition_id; } /** * Assigned partition for all client messages inside this batch. * This actual partition may differ from that returned in InitResponse * or other WriteResponses in this write session. * * Generated from protobuf field <code>int64 partition_id = 2;</code> * @param int|string $var * @return $this */ public function setPartitionId($var) { GPBUtil::checkInt64($var); $this->partition_id = $var; return $this; } /** * Write statistics for this sequence of client messages. * * Generated from protobuf field <code>.Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;</code> * @return \Ydb\Topic\StreamWriteMessage\WriteResponse\WriteStatistics|null */ public function getWriteStatistics() { return $this->write_statistics; } public function hasWriteStatistics() { return isset($this->write_statistics); } public function clearWriteStatistics() { unset($this->write_statistics); } /** * Write statistics for this sequence of client messages. * * Generated from protobuf field <code>.Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;</code> * @param \Ydb\Topic\StreamWriteMessage\WriteResponse\WriteStatistics $var * @return $this */ public function setWriteStatistics($var) { GPBUtil::checkMessage($var, \Ydb\Topic\StreamWriteMessage\WriteResponse\WriteStatistics::class); $this->write_statistics = $var; return $this; } } // Adding a class alias for backwards compatibility with the previous class name. class_alias(WriteResponse::class, \Ydb\Topic\StreamWriteMessage_WriteResponse::class);