Ydb.Table.BulkUpsertRequest
*/
class BulkUpsertRequest extends \Google\Protobuf\Internal\Message
{
/**
* Generated from protobuf field string table = 1;
*/
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 .Ydb.TypedValue rows = 2;
*/
protected $rows = null;
/**
* Generated from protobuf field .Ydb.Operations.OperationParams operation_params = 3;
*/
protected $operation_params = null;
/**
* It's last in the definition to help with sidecar patterns
*
* Generated from protobuf field bytes data = 1000;
*/
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 string table = 1;
* @return string
*/
public function getTable()
{
return $this->table;
}
/**
* Generated from protobuf field string table = 1;
* @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 .Ydb.TypedValue rows = 2;
* @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 .Ydb.TypedValue rows = 2;
* @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 .Ydb.Operations.OperationParams operation_params = 3;
* @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 .Ydb.Operations.OperationParams operation_params = 3;
* @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 .Ydb.Formats.ArrowBatchSettings arrow_batch_settings = 7;
* @return \Ydb\Formats\ArrowBatchSettings|null
*/
public function getArrowBatchSettings()
{
return $this->readOneof(7);
}
public function hasArrowBatchSettings()
{
return $this->hasOneof(7);
}
/**
* Generated from protobuf field .Ydb.Formats.ArrowBatchSettings arrow_batch_settings = 7;
* @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 .Ydb.Formats.CsvSettings csv_settings = 8;
* @return \Ydb\Formats\CsvSettings|null
*/
public function getCsvSettings()
{
return $this->readOneof(8);
}
public function hasCsvSettings()
{
return $this->hasOneof(8);
}
/**
* Generated from protobuf field .Ydb.Formats.CsvSettings csv_settings = 8;
* @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 bytes data = 1000;
* @return string
*/
public function getData()
{
return $this->data;
}
/**
* It's last in the definition to help with sidecar patterns
*
* Generated from protobuf field bytes data = 1000;
* @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");
}
}