Ydb.Topic.StreamReadMessage.ReadResponse.MessageData */ class MessageData extends \Google\Protobuf\Internal\Message { /** * Partition offset in partition that assigned for message. * * Generated from protobuf field int64 offset = 1; */ protected $offset = 0; /** * Sequence number that provided with message on write from client. * * Generated from protobuf field int64 seq_no = 2; */ protected $seq_no = 0; /** * Timestamp of creation of message provided on write from client. * * Generated from protobuf field .google.protobuf.Timestamp created_at = 3; */ protected $created_at = null; /** * Compressed client message body. * * Generated from protobuf field bytes data = 5; */ protected $data = ''; /** * Uncompressed size of client message body. * sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer). * Use it for optimization purposes only, don't trust it. * * Generated from protobuf field int64 uncompressed_size = 6; */ protected $uncompressed_size = 0; /** * Filled if message_group_id was set on message write. * * Generated from protobuf field string message_group_id = 7; */ protected $message_group_id = ''; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type int|string $offset * Partition offset in partition that assigned for message. * @type int|string $seq_no * Sequence number that provided with message on write from client. * @type \Google\Protobuf\Timestamp $created_at * Timestamp of creation of message provided on write from client. * @type string $data * Compressed client message body. * @type int|string $uncompressed_size * Uncompressed size of client message body. * sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer). * Use it for optimization purposes only, don't trust it. * @type string $message_group_id * Filled if message_group_id was set on message write. * } */ public function __construct($data = NULL) { \GPBMetadata\Protos\YdbTopic::initOnce(); parent::__construct($data); } /** * Partition offset in partition that assigned for message. * * Generated from protobuf field int64 offset = 1; * @return int|string */ public function getOffset() { return $this->offset; } /** * Partition offset in partition that assigned for message. * * Generated from protobuf field int64 offset = 1; * @param int|string $var * @return $this */ public function setOffset($var) { GPBUtil::checkInt64($var); $this->offset = $var; return $this; } /** * Sequence number that provided with message on write from client. * * Generated from protobuf field int64 seq_no = 2; * @return int|string */ public function getSeqNo() { return $this->seq_no; } /** * Sequence number that provided with message on write from client. * * Generated from protobuf field int64 seq_no = 2; * @param int|string $var * @return $this */ public function setSeqNo($var) { GPBUtil::checkInt64($var); $this->seq_no = $var; return $this; } /** * Timestamp of creation of message provided on write from client. * * Generated from protobuf field .google.protobuf.Timestamp created_at = 3; * @return \Google\Protobuf\Timestamp|null */ public function getCreatedAt() { return $this->created_at; } public function hasCreatedAt() { return isset($this->created_at); } public function clearCreatedAt() { unset($this->created_at); } /** * Timestamp of creation of message provided on write from client. * * Generated from protobuf field .google.protobuf.Timestamp created_at = 3; * @param \Google\Protobuf\Timestamp $var * @return $this */ public function setCreatedAt($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); $this->created_at = $var; return $this; } /** * Compressed client message body. * * Generated from protobuf field bytes data = 5; * @return string */ public function getData() { return $this->data; } /** * Compressed client message body. * * Generated from protobuf field bytes data = 5; * @param string $var * @return $this */ public function setData($var) { GPBUtil::checkString($var, False); $this->data = $var; return $this; } /** * Uncompressed size of client message body. * sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer). * Use it for optimization purposes only, don't trust it. * * Generated from protobuf field int64 uncompressed_size = 6; * @return int|string */ public function getUncompressedSize() { return $this->uncompressed_size; } /** * Uncompressed size of client message body. * sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer). * Use it for optimization purposes only, don't trust it. * * Generated from protobuf field int64 uncompressed_size = 6; * @param int|string $var * @return $this */ public function setUncompressedSize($var) { GPBUtil::checkInt64($var); $this->uncompressed_size = $var; return $this; } /** * Filled if message_group_id was set on message write. * * Generated from protobuf field string message_group_id = 7; * @return string */ public function getMessageGroupId() { return $this->message_group_id; } /** * Filled if message_group_id was set on message write. * * Generated from protobuf field string message_group_id = 7; * @param string $var * @return $this */ public function setMessageGroupId($var) { GPBUtil::checkString($var, True); $this->message_group_id = $var; return $this; } } // Adding a class alias for backwards compatibility with the previous class name. class_alias(MessageData::class, \Ydb\Topic\StreamReadMessage_ReadResponse_MessageData::class);