Ydb.Cms.CreateDatabaseRequest */ class CreateDatabaseRequest extends \Google\Protobuf\Internal\Message { /** * Generated from protobuf field .Ydb.Operations.OperationParams operation_params = 1; */ protected $operation_params = null; /** * Required. Full path to database's home dir. Used as database ID. * * Generated from protobuf field string path = 2; */ protected $path = ''; /** * Additional database options. * * Generated from protobuf field .Ydb.Cms.DatabaseOptions options = 4; */ protected $options = null; /** * Attach attributes to database. * * Generated from protobuf field map attributes = 5; */ private $attributes; /** * Optional quotas for schema operations * * Generated from protobuf field .Ydb.Cms.SchemaOperationQuotas schema_operation_quotas = 8; */ protected $schema_operation_quotas = null; /** * Optional idempotency key * * Generated from protobuf field string idempotency_key = 9; */ protected $idempotency_key = ''; /** * Optional quotas for the database * * Generated from protobuf field .Ydb.Cms.DatabaseQuotas database_quotas = 10; */ protected $database_quotas = null; protected $resources_kind; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type \Ydb\Operations\OperationParams $operation_params * @type string $path * Required. Full path to database's home dir. Used as database ID. * @type \Ydb\Cms\Resources $resources * Resources to allocate for database by CMS. * @type \Ydb\Cms\Resources $shared_resources * Shared resources can be used by serverless databases. * @type \Ydb\Cms\ServerlessResources $serverless_resources * If specified, the created database will be "serverless". * @type \Ydb\Cms\DatabaseOptions $options * Additional database options. * @type array|\Google\Protobuf\Internal\MapField $attributes * Attach attributes to database. * @type \Ydb\Cms\SchemaOperationQuotas $schema_operation_quotas * Optional quotas for schema operations * @type string $idempotency_key * Optional idempotency key * @type \Ydb\Cms\DatabaseQuotas $database_quotas * Optional quotas for the database * } */ public function __construct($data = NULL) { \GPBMetadata\Protos\YdbCms::initOnce(); parent::__construct($data); } /** * Generated from protobuf field .Ydb.Operations.OperationParams operation_params = 1; * @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 = 1; * @param \Ydb\Operations\OperationParams $var * @return $this */ public function setOperationParams($var) { GPBUtil::checkMessage($var, \Ydb\Operations\OperationParams::class); $this->operation_params = $var; return $this; } /** * Required. Full path to database's home dir. Used as database ID. * * Generated from protobuf field string path = 2; * @return string */ public function getPath() { return $this->path; } /** * Required. Full path to database's home dir. Used as database ID. * * Generated from protobuf field string path = 2; * @param string $var * @return $this */ public function setPath($var) { GPBUtil::checkString($var, True); $this->path = $var; return $this; } /** * Resources to allocate for database by CMS. * * Generated from protobuf field .Ydb.Cms.Resources resources = 3; * @return \Ydb\Cms\Resources|null */ public function getResources() { return $this->readOneof(3); } public function hasResources() { return $this->hasOneof(3); } /** * Resources to allocate for database by CMS. * * Generated from protobuf field .Ydb.Cms.Resources resources = 3; * @param \Ydb\Cms\Resources $var * @return $this */ public function setResources($var) { GPBUtil::checkMessage($var, \Ydb\Cms\Resources::class); $this->writeOneof(3, $var); return $this; } /** * Shared resources can be used by serverless databases. * * Generated from protobuf field .Ydb.Cms.Resources shared_resources = 6; * @return \Ydb\Cms\Resources|null */ public function getSharedResources() { return $this->readOneof(6); } public function hasSharedResources() { return $this->hasOneof(6); } /** * Shared resources can be used by serverless databases. * * Generated from protobuf field .Ydb.Cms.Resources shared_resources = 6; * @param \Ydb\Cms\Resources $var * @return $this */ public function setSharedResources($var) { GPBUtil::checkMessage($var, \Ydb\Cms\Resources::class); $this->writeOneof(6, $var); return $this; } /** * If specified, the created database will be "serverless". * * Generated from protobuf field .Ydb.Cms.ServerlessResources serverless_resources = 7; * @return \Ydb\Cms\ServerlessResources|null */ public function getServerlessResources() { return $this->readOneof(7); } public function hasServerlessResources() { return $this->hasOneof(7); } /** * If specified, the created database will be "serverless". * * Generated from protobuf field .Ydb.Cms.ServerlessResources serverless_resources = 7; * @param \Ydb\Cms\ServerlessResources $var * @return $this */ public function setServerlessResources($var) { GPBUtil::checkMessage($var, \Ydb\Cms\ServerlessResources::class); $this->writeOneof(7, $var); return $this; } /** * Additional database options. * * Generated from protobuf field .Ydb.Cms.DatabaseOptions options = 4; * @return \Ydb\Cms\DatabaseOptions|null */ public function getOptions() { return $this->options; } public function hasOptions() { return isset($this->options); } public function clearOptions() { unset($this->options); } /** * Additional database options. * * Generated from protobuf field .Ydb.Cms.DatabaseOptions options = 4; * @param \Ydb\Cms\DatabaseOptions $var * @return $this */ public function setOptions($var) { GPBUtil::checkMessage($var, \Ydb\Cms\DatabaseOptions::class); $this->options = $var; return $this; } /** * Attach attributes to database. * * Generated from protobuf field map attributes = 5; * @return \Google\Protobuf\Internal\MapField */ public function getAttributes() { return $this->attributes; } /** * Attach attributes to database. * * Generated from protobuf field map attributes = 5; * @param array|\Google\Protobuf\Internal\MapField $var * @return $this */ public function setAttributes($var) { $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); $this->attributes = $arr; return $this; } /** * Optional quotas for schema operations * * Generated from protobuf field .Ydb.Cms.SchemaOperationQuotas schema_operation_quotas = 8; * @return \Ydb\Cms\SchemaOperationQuotas|null */ public function getSchemaOperationQuotas() { return $this->schema_operation_quotas; } public function hasSchemaOperationQuotas() { return isset($this->schema_operation_quotas); } public function clearSchemaOperationQuotas() { unset($this->schema_operation_quotas); } /** * Optional quotas for schema operations * * Generated from protobuf field .Ydb.Cms.SchemaOperationQuotas schema_operation_quotas = 8; * @param \Ydb\Cms\SchemaOperationQuotas $var * @return $this */ public function setSchemaOperationQuotas($var) { GPBUtil::checkMessage($var, \Ydb\Cms\SchemaOperationQuotas::class); $this->schema_operation_quotas = $var; return $this; } /** * Optional idempotency key * * Generated from protobuf field string idempotency_key = 9; * @return string */ public function getIdempotencyKey() { return $this->idempotency_key; } /** * Optional idempotency key * * Generated from protobuf field string idempotency_key = 9; * @param string $var * @return $this */ public function setIdempotencyKey($var) { GPBUtil::checkString($var, True); $this->idempotency_key = $var; return $this; } /** * Optional quotas for the database * * Generated from protobuf field .Ydb.Cms.DatabaseQuotas database_quotas = 10; * @return \Ydb\Cms\DatabaseQuotas|null */ public function getDatabaseQuotas() { return $this->database_quotas; } public function hasDatabaseQuotas() { return isset($this->database_quotas); } public function clearDatabaseQuotas() { unset($this->database_quotas); } /** * Optional quotas for the database * * Generated from protobuf field .Ydb.Cms.DatabaseQuotas database_quotas = 10; * @param \Ydb\Cms\DatabaseQuotas $var * @return $this */ public function setDatabaseQuotas($var) { GPBUtil::checkMessage($var, \Ydb\Cms\DatabaseQuotas::class); $this->database_quotas = $var; return $this; } /** * @return string */ public function getResourcesKind() { return $this->whichOneof("resources_kind"); } }