123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246 |
- <?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.BulkUpsertRequest</code>
- */
- class BulkUpsertRequest extends \Google\Protobuf\Internal\Message
- {
- /**
- * Generated from protobuf field <code>string table = 1;</code>
- */
- protected $table = '';
- /**
- * "rows" parameter must be a list of structs where each stuct represents one row.
- * It must contain all key columns but not necessarily all non-key columns.
- * Similar to UPSERT statement only values of specified columns will be updated.
- *
- * Generated from protobuf field <code>.Ydb.TypedValue rows = 2;</code>
- */
- protected $rows = null;
- /**
- * Generated from protobuf field <code>.Ydb.Operations.OperationParams operation_params = 3;</code>
- */
- protected $operation_params = null;
- /**
- * It's last in the definition to help with sidecar patterns
- *
- * Generated from protobuf field <code>bytes data = 1000;</code>
- */
- protected $data = '';
- protected $data_format;
- /**
- * Constructor.
- *
- * @param array $data {
- * Optional. Data for populating the Message object.
- *
- * @type string $table
- * @type \Ydb\TypedValue $rows
- * "rows" parameter must be a list of structs where each stuct represents one row.
- * It must contain all key columns but not necessarily all non-key columns.
- * Similar to UPSERT statement only values of specified columns will be updated.
- * @type \Ydb\Operations\OperationParams $operation_params
- * @type \Ydb\Formats\ArrowBatchSettings $arrow_batch_settings
- * @type \Ydb\Formats\CsvSettings $csv_settings
- * @type string $data
- * It's last in the definition to help with sidecar patterns
- * }
- */
- public function __construct($data = NULL) {
- \GPBMetadata\Protos\YdbTable::initOnce();
- parent::__construct($data);
- }
- /**
- * Generated from protobuf field <code>string table = 1;</code>
- * @return string
- */
- public function getTable()
- {
- return $this->table;
- }
- /**
- * Generated from protobuf field <code>string table = 1;</code>
- * @param string $var
- * @return $this
- */
- public function setTable($var)
- {
- GPBUtil::checkString($var, True);
- $this->table = $var;
- return $this;
- }
- /**
- * "rows" parameter must be a list of structs where each stuct represents one row.
- * It must contain all key columns but not necessarily all non-key columns.
- * Similar to UPSERT statement only values of specified columns will be updated.
- *
- * Generated from protobuf field <code>.Ydb.TypedValue rows = 2;</code>
- * @return \Ydb\TypedValue|null
- */
- public function getRows()
- {
- return $this->rows;
- }
- public function hasRows()
- {
- return isset($this->rows);
- }
- public function clearRows()
- {
- unset($this->rows);
- }
- /**
- * "rows" parameter must be a list of structs where each stuct represents one row.
- * It must contain all key columns but not necessarily all non-key columns.
- * Similar to UPSERT statement only values of specified columns will be updated.
- *
- * Generated from protobuf field <code>.Ydb.TypedValue rows = 2;</code>
- * @param \Ydb\TypedValue $var
- * @return $this
- */
- public function setRows($var)
- {
- GPBUtil::checkMessage($var, \Ydb\TypedValue::class);
- $this->rows = $var;
- return $this;
- }
- /**
- * Generated from protobuf field <code>.Ydb.Operations.OperationParams operation_params = 3;</code>
- * @return \Ydb\Operations\OperationParams|null
- */
- public function getOperationParams()
- {
- return $this->operation_params;
- }
- public function hasOperationParams()
- {
- return isset($this->operation_params);
- }
- public function clearOperationParams()
- {
- unset($this->operation_params);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Operations.OperationParams operation_params = 3;</code>
- * @param \Ydb\Operations\OperationParams $var
- * @return $this
- */
- public function setOperationParams($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Operations\OperationParams::class);
- $this->operation_params = $var;
- return $this;
- }
- /**
- * Generated from protobuf field <code>.Ydb.Formats.ArrowBatchSettings arrow_batch_settings = 7;</code>
- * @return \Ydb\Formats\ArrowBatchSettings|null
- */
- public function getArrowBatchSettings()
- {
- return $this->readOneof(7);
- }
- public function hasArrowBatchSettings()
- {
- return $this->hasOneof(7);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Formats.ArrowBatchSettings arrow_batch_settings = 7;</code>
- * @param \Ydb\Formats\ArrowBatchSettings $var
- * @return $this
- */
- public function setArrowBatchSettings($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Formats\ArrowBatchSettings::class);
- $this->writeOneof(7, $var);
- return $this;
- }
- /**
- * Generated from protobuf field <code>.Ydb.Formats.CsvSettings csv_settings = 8;</code>
- * @return \Ydb\Formats\CsvSettings|null
- */
- public function getCsvSettings()
- {
- return $this->readOneof(8);
- }
- public function hasCsvSettings()
- {
- return $this->hasOneof(8);
- }
- /**
- * Generated from protobuf field <code>.Ydb.Formats.CsvSettings csv_settings = 8;</code>
- * @param \Ydb\Formats\CsvSettings $var
- * @return $this
- */
- public function setCsvSettings($var)
- {
- GPBUtil::checkMessage($var, \Ydb\Formats\CsvSettings::class);
- $this->writeOneof(8, $var);
- return $this;
- }
- /**
- * It's last in the definition to help with sidecar patterns
- *
- * Generated from protobuf field <code>bytes data = 1000;</code>
- * @return string
- */
- public function getData()
- {
- return $this->data;
- }
- /**
- * It's last in the definition to help with sidecar patterns
- *
- * Generated from protobuf field <code>bytes data = 1000;</code>
- * @param string $var
- * @return $this
- */
- public function setData($var)
- {
- GPBUtil::checkString($var, False);
- $this->data = $var;
- return $this;
- }
- /**
- * @return string
- */
- public function getDataFormat()
- {
- return $this->whichOneof("data_format");
- }
- }
|