123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152 |
- <?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.TransactionSettings</code>
- */
- class TransactionSettings extends \Google\Protobuf\Internal\Message
- {
- protected $tx_mode;
- /**
- * Constructor.
- *
- * @param array $data {
- * Optional. Data for populating the Message object.
- *
- * @type \Ydb\Table\SerializableModeSettings $serializable_read_write
- * @type \Ydb\Table\OnlineModeSettings $online_read_only
- * @type \Ydb\Table\StaleModeSettings $stale_read_only
- * @type \Ydb\Table\SnapshotModeSettings $snapshot_read_only
- * }
- */
- public function __construct($data = NULL) {
- \GPBMetadata\Protos\YdbTable::initOnce();
- parent::__construct($data);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.SerializableModeSettings serializable_read_write = 1;</code>
- * @return \Ydb\Table\SerializableModeSettings|null
- */
- public function getSerializableReadWrite()
- {
- return $this->readOneof(1);
- }
- public function hasSerializableReadWrite()
- {
- return $this->hasOneof(1);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.SerializableModeSettings serializable_read_write = 1;</code>
- * @param \Ydb\Table\SerializableModeSettings $var
- * @return $this
- */
- public function setSerializableReadWrite($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Table\SerializableModeSettings::class);
- $this->writeOneof(1, $var);
- return $this;
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.OnlineModeSettings online_read_only = 2;</code>
- * @return \Ydb\Table\OnlineModeSettings|null
- */
- public function getOnlineReadOnly()
- {
- return $this->readOneof(2);
- }
- public function hasOnlineReadOnly()
- {
- return $this->hasOneof(2);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.OnlineModeSettings online_read_only = 2;</code>
- * @param \Ydb\Table\OnlineModeSettings $var
- * @return $this
- */
- public function setOnlineReadOnly($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Table\OnlineModeSettings::class);
- $this->writeOneof(2, $var);
- return $this;
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.StaleModeSettings stale_read_only = 3;</code>
- * @return \Ydb\Table\StaleModeSettings|null
- */
- public function getStaleReadOnly()
- {
- return $this->readOneof(3);
- }
- public function hasStaleReadOnly()
- {
- return $this->hasOneof(3);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.StaleModeSettings stale_read_only = 3;</code>
- * @param \Ydb\Table\StaleModeSettings $var
- * @return $this
- */
- public function setStaleReadOnly($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Table\StaleModeSettings::class);
- $this->writeOneof(3, $var);
- return $this;
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.SnapshotModeSettings snapshot_read_only = 4;</code>
- * @return \Ydb\Table\SnapshotModeSettings|null
- */
- public function getSnapshotReadOnly()
- {
- return $this->readOneof(4);
- }
- public function hasSnapshotReadOnly()
- {
- return $this->hasOneof(4);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Table.SnapshotModeSettings snapshot_read_only = 4;</code>
- * @param \Ydb\Table\SnapshotModeSettings $var
- * @return $this
- */
- public function setSnapshotReadOnly($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Table\SnapshotModeSettings::class);
- $this->writeOneof(4, $var);
- return $this;
- }
- /**
- * @return string
- */
- public function getTxMode()
- {
- return $this->whichOneof("tx_mode");
- }
- }
|