123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249 |
- <?php
- # Generated by the protocol buffer compiler. DO NOT EDIT!
- # source: protos/ydb_topic.proto
- namespace Ydb\Topic;
- use Google\Protobuf\Internal\GPBType;
- use Google\Protobuf\Internal\RepeatedField;
- use Google\Protobuf\Internal\GPBUtil;
- /**
- * Consumer alter description.
- *
- * Generated from protobuf message <code>Ydb.Topic.AlterConsumer</code>
- */
- class AlterConsumer extends \Google\Protobuf\Internal\Message
- {
- /**
- * Must have valid not empty name as a key.
- *
- * Generated from protobuf field <code>string name = 1;</code>
- */
- protected $name = '';
- /**
- * Consumer may be marked as 'important'. It means messages for this consumer will never expire due to retention.
- * User should take care that such consumer never stalls, to prevent running out of disk space.
- * Flag that this consumer is important.
- *
- * Generated from protobuf field <code>optional bool set_important = 2;</code>
- */
- protected $set_important = null;
- /**
- * All messages with smaller server written_at timestamp will be skipped.
- *
- * Generated from protobuf field <code>.google.protobuf.Timestamp set_read_from = 3;</code>
- */
- protected $set_read_from = null;
- /**
- * List of supported codecs by this consumer.
- * supported_codecs on topic must be contained inside this list.
- *
- * Generated from protobuf field <code>.Ydb.Topic.SupportedCodecs set_supported_codecs = 5;</code>
- */
- protected $set_supported_codecs = null;
- /**
- * User and server attributes of consumer. Server attributes starts from "_" and will be validated by server.
- * Leave the value blank to drop an attribute.
- *
- * Generated from protobuf field <code>map<string, string> alter_attributes = 6;</code>
- */
- private $alter_attributes;
- /**
- * Constructor.
- *
- * @param array $data {
- * Optional. Data for populating the Message object.
- *
- * @type string $name
- * Must have valid not empty name as a key.
- * @type bool $set_important
- * Consumer may be marked as 'important'. It means messages for this consumer will never expire due to retention.
- * User should take care that such consumer never stalls, to prevent running out of disk space.
- * Flag that this consumer is important.
- * @type \Google\Protobuf\Timestamp $set_read_from
- * All messages with smaller server written_at timestamp will be skipped.
- * @type \Ydb\Topic\SupportedCodecs $set_supported_codecs
- * List of supported codecs by this consumer.
- * supported_codecs on topic must be contained inside this list.
- * @type array|\Google\Protobuf\Internal\MapField $alter_attributes
- * User and server attributes of consumer. Server attributes starts from "_" and will be validated by server.
- * Leave the value blank to drop an attribute.
- * }
- */
- public function __construct($data = NULL) {
- \GPBMetadata\Protos\YdbTopic::initOnce();
- parent::__construct($data);
- }
- /**
- * Must have valid not empty name as a key.
- *
- * Generated from protobuf field <code>string name = 1;</code>
- * @return string
- */
- public function getName()
- {
- return $this->name;
- }
- /**
- * Must have valid not empty name as a key.
- *
- * Generated from protobuf field <code>string name = 1;</code>
- * @param string $var
- * @return $this
- */
- public function setName($var)
- {
- GPBUtil::checkString($var, True);
- $this->name = $var;
- return $this;
- }
- /**
- * Consumer may be marked as 'important'. It means messages for this consumer will never expire due to retention.
- * User should take care that such consumer never stalls, to prevent running out of disk space.
- * Flag that this consumer is important.
- *
- * Generated from protobuf field <code>optional bool set_important = 2;</code>
- * @return bool
- */
- public function getSetImportant()
- {
- return isset($this->set_important) ? $this->set_important : false;
- }
- public function hasSetImportant()
- {
- return isset($this->set_important);
- }
- public function clearSetImportant()
- {
- unset($this->set_important);
- }
- /**
- * Consumer may be marked as 'important'. It means messages for this consumer will never expire due to retention.
- * User should take care that such consumer never stalls, to prevent running out of disk space.
- * Flag that this consumer is important.
- *
- * Generated from protobuf field <code>optional bool set_important = 2;</code>
- * @param bool $var
- * @return $this
- */
- public function setSetImportant($var)
- {
- GPBUtil::checkBool($var);
- $this->set_important = $var;
- return $this;
- }
- /**
- * All messages with smaller server written_at timestamp will be skipped.
- *
- * Generated from protobuf field <code>.google.protobuf.Timestamp set_read_from = 3;</code>
- * @return \Google\Protobuf\Timestamp|null
- */
- public function getSetReadFrom()
- {
- return $this->set_read_from;
- }
- public function hasSetReadFrom()
- {
- return isset($this->set_read_from);
- }
- public function clearSetReadFrom()
- {
- unset($this->set_read_from);
- }
- /**
- * All messages with smaller server written_at timestamp will be skipped.
- *
- * Generated from protobuf field <code>.google.protobuf.Timestamp set_read_from = 3;</code>
- * @param \Google\Protobuf\Timestamp $var
- * @return $this
- */
- public function setSetReadFrom($var)
- {
- GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
- $this->set_read_from = $var;
- return $this;
- }
- /**
- * List of supported codecs by this consumer.
- * supported_codecs on topic must be contained inside this list.
- *
- * Generated from protobuf field <code>.Ydb.Topic.SupportedCodecs set_supported_codecs = 5;</code>
- * @return \Ydb\Topic\SupportedCodecs|null
- */
- public function getSetSupportedCodecs()
- {
- return $this->set_supported_codecs;
- }
- public function hasSetSupportedCodecs()
- {
- return isset($this->set_supported_codecs);
- }
- public function clearSetSupportedCodecs()
- {
- unset($this->set_supported_codecs);
- }
- /**
- * List of supported codecs by this consumer.
- * supported_codecs on topic must be contained inside this list.
- *
- * Generated from protobuf field <code>.Ydb.Topic.SupportedCodecs set_supported_codecs = 5;</code>
- * @param \Ydb\Topic\SupportedCodecs $var
- * @return $this
- */
- public function setSetSupportedCodecs($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Topic\SupportedCodecs::class);
- $this->set_supported_codecs = $var;
- return $this;
- }
- /**
- * User and server attributes of consumer. Server attributes starts from "_" and will be validated by server.
- * Leave the value blank to drop an attribute.
- *
- * Generated from protobuf field <code>map<string, string> alter_attributes = 6;</code>
- * @return \Google\Protobuf\Internal\MapField
- */
- public function getAlterAttributes()
- {
- return $this->alter_attributes;
- }
- /**
- * User and server attributes of consumer. Server attributes starts from "_" and will be validated by server.
- * Leave the value blank to drop an attribute.
- *
- * Generated from protobuf field <code>map<string, string> alter_attributes = 6;</code>
- * @param array|\Google\Protobuf\Internal\MapField $var
- * @return $this
- */
- public function setAlterAttributes($var)
- {
- $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING);
- $this->alter_attributes = $arr;
- return $this;
- }
- }
|