Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings */ class TopicReadSettings extends \Google\Protobuf\Internal\Message { /** * Topic path. * * Generated from protobuf field string path = 1; */ protected $path = ''; /** * Partitions that will be read by this session. * If list is empty - then session will read all partitions. * * Generated from protobuf field repeated int64 partition_ids = 2; */ private $partition_ids; /** * Skip all messages that has write timestamp smaller than now - max_lag. * Zero means infinite lag. * * Generated from protobuf field .google.protobuf.Duration max_lag = 3; */ protected $max_lag = null; /** * Read data only after this timestamp from this topic. * Read only messages with 'written_at' value greater or equal than this timestamp. * * Generated from protobuf field .google.protobuf.Timestamp read_from = 4; */ protected $read_from = null; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $path * Topic path. * @type array|array|\Google\Protobuf\Internal\RepeatedField $partition_ids * Partitions that will be read by this session. * If list is empty - then session will read all partitions. * @type \Google\Protobuf\Duration $max_lag * Skip all messages that has write timestamp smaller than now - max_lag. * Zero means infinite lag. * @type \Google\Protobuf\Timestamp $read_from * Read data only after this timestamp from this topic. * Read only messages with 'written_at' value greater or equal than this timestamp. * } */ public function __construct($data = NULL) { \GPBMetadata\Protos\YdbTopic::initOnce(); parent::__construct($data); } /** * Topic path. * * Generated from protobuf field string path = 1; * @return string */ public function getPath() { return $this->path; } /** * Topic path. * * Generated from protobuf field string path = 1; * @param string $var * @return $this */ public function setPath($var) { GPBUtil::checkString($var, True); $this->path = $var; return $this; } /** * Partitions that will be read by this session. * If list is empty - then session will read all partitions. * * Generated from protobuf field repeated int64 partition_ids = 2; * @return \Google\Protobuf\Internal\RepeatedField */ public function getPartitionIds() { return $this->partition_ids; } /** * Partitions that will be read by this session. * If list is empty - then session will read all partitions. * * Generated from protobuf field repeated int64 partition_ids = 2; * @param array|array|\Google\Protobuf\Internal\RepeatedField $var * @return $this */ public function setPartitionIds($var) { $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT64); $this->partition_ids = $arr; return $this; } /** * Skip all messages that has write timestamp smaller than now - max_lag. * Zero means infinite lag. * * Generated from protobuf field .google.protobuf.Duration max_lag = 3; * @return \Google\Protobuf\Duration|null */ public function getMaxLag() { return $this->max_lag; } public function hasMaxLag() { return isset($this->max_lag); } public function clearMaxLag() { unset($this->max_lag); } /** * Skip all messages that has write timestamp smaller than now - max_lag. * Zero means infinite lag. * * Generated from protobuf field .google.protobuf.Duration max_lag = 3; * @param \Google\Protobuf\Duration $var * @return $this */ public function setMaxLag($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); $this->max_lag = $var; return $this; } /** * Read data only after this timestamp from this topic. * Read only messages with 'written_at' value greater or equal than this timestamp. * * Generated from protobuf field .google.protobuf.Timestamp read_from = 4; * @return \Google\Protobuf\Timestamp|null */ public function getReadFrom() { return $this->read_from; } public function hasReadFrom() { return isset($this->read_from); } public function clearReadFrom() { unset($this->read_from); } /** * Read data only after this timestamp from this topic. * Read only messages with 'written_at' value greater or equal than this timestamp. * * Generated from protobuf field .google.protobuf.Timestamp read_from = 4; * @param \Google\Protobuf\Timestamp $var * @return $this */ public function setReadFrom($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); $this->read_from = $var; return $this; } } // Adding a class alias for backwards compatibility with the previous class name. class_alias(TopicReadSettings::class, \Ydb\Topic\StreamReadMessage_InitRequest_TopicReadSettings::class);