/
githubmirror
/
ydb-php-sdk
Обзор
Документация
Войти
/
githubmirror
/
ydb-php-sdk
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
protos/Ydb/Table/ReplicationPolicy.php
175 строк
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_table.proto namespace Ydb\Table; use Google\Protobuf\Internal\GPBType; use Google\Protobuf\Internal\RepeatedField; use Google\Protobuf\Internal\GPBUtil; /** * Generated from protobuf message <code>Ydb.Table.ReplicationPolicy</code> */ class ReplicationPolicy extends \Google\Protobuf\Internal\Message { /** * Generated from protobuf field <code>string preset_name = 1;</code> */ protected $preset_name = ''; /** * If value is non-zero then it specifies a number of read-only * replicas to create for a table. Zero value means preset * setting usage. * * Generated from protobuf field <code>uint32 replicas_count = 2;</code> */ protected $replicas_count = 0; /** * If this feature in enabled then requested number of replicas * will be created in each availability zone. * * Generated from protobuf field <code>.Ydb.FeatureFlag.Status create_per_availability_zone = 3;</code> */ protected $create_per_availability_zone = 0; /** * If this feature in enabled then read-only replicas can be promoted * to leader. * * Generated from protobuf field <code>.Ydb.FeatureFlag.Status allow_promotion = 4;</code> */ protected $allow_promotion = 0; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $preset_name * @type int $replicas_count * If value is non-zero then it specifies a number of read-only * replicas to create for a table. Zero value means preset * setting usage. * @type int $create_per_availability_zone * If this feature in enabled then requested number of replicas * will be created in each availability zone. * @type int $allow_promotion * If this feature in enabled then read-only replicas can be promoted * to leader. * } */ public function __construct($data = NULL) { \GPBMetadata\Protos\YdbTable::initOnce(); parent::__construct($data); } /** * Generated from protobuf field <code>string preset_name = 1;</code> * @return string */ public function getPresetName() { return $this->preset_name; } /** * Generated from protobuf field <code>string preset_name = 1;</code> * @param string $var * @return $this */ public function setPresetName($var) { GPBUtil::checkString($var, True); $this->preset_name = $var; return $this; } /** * If value is non-zero then it specifies a number of read-only * replicas to create for a table. Zero value means preset * setting usage. * * Generated from protobuf field <code>uint32 replicas_count = 2;</code> * @return int */ public function getReplicasCount() { return $this->replicas_count; } /** * If value is non-zero then it specifies a number of read-only * replicas to create for a table. Zero value means preset * setting usage. * * Generated from protobuf field <code>uint32 replicas_count = 2;</code> * @param int $var * @return $this */ public function setReplicasCount($var) { GPBUtil::checkUint32($var); $this->replicas_count = $var; return $this; } /** * If this feature in enabled then requested number of replicas * will be created in each availability zone. * * Generated from protobuf field <code>.Ydb.FeatureFlag.Status create_per_availability_zone = 3;</code> * @return int */ public function getCreatePerAvailabilityZone() { return $this->create_per_availability_zone; } /** * If this feature in enabled then requested number of replicas * will be created in each availability zone. * * Generated from protobuf field <code>.Ydb.FeatureFlag.Status create_per_availability_zone = 3;</code> * @param int $var * @return $this */ public function setCreatePerAvailabilityZone($var) { GPBUtil::checkEnum($var, \Ydb\FeatureFlag\Status::class); $this->create_per_availability_zone = $var; return $this; } /** * If this feature in enabled then read-only replicas can be promoted * to leader. * * Generated from protobuf field <code>.Ydb.FeatureFlag.Status allow_promotion = 4;</code> * @return int */ public function getAllowPromotion() { return $this->allow_promotion; } /** * If this feature in enabled then read-only replicas can be promoted * to leader. * * Generated from protobuf field <code>.Ydb.FeatureFlag.Status allow_promotion = 4;</code> * @param int $var * @return $this */ public function setAllowPromotion($var) { GPBUtil::checkEnum($var, \Ydb\FeatureFlag\Status::class); $this->allow_promotion = $var; return $this; } }