Class UpdateInstanceRequestBuilder (2.24.0)
Stay organized with collections
Save and categorize content based on your preferences.
This is useful when calling google::cloud::spanner::InstanceAdminClient::UpdateInstance()
function.
Example
void UpdateInstance(google::cloud::spanner_admin::InstanceAdminClient client,
std::string const& project_id,
std::string const& instance_id,
std::string const& new_display_name) {
google::cloud::spanner::Instance in(project_id, instance_id);
auto f = client.UpdateInstance(
google::cloud::spanner::UpdateInstanceRequestBuilder(in)
.SetDisplayName(new_display_name)
.Build());
auto instance = f.get();
if (!instance) throw std::move(instance).status();
std::cout << "Updated instance [" << in << "]\n";
}
Constructors
UpdateInstanceRequestBuilder()
UpdateInstanceRequestBuilder(UpdateInstanceRequestBuilder const &)
Parameter |
Name |
Description |
|
UpdateInstanceRequestBuilder const &
|
UpdateInstanceRequestBuilder(UpdateInstanceRequestBuilder &&)
Parameter |
Name |
Description |
|
UpdateInstanceRequestBuilder &&
|
UpdateInstanceRequestBuilder(std::string)
Parameter |
Name |
Description |
instance_name |
std::string
|
UpdateInstanceRequestBuilder(Instance const &)
Parameter |
Name |
Description |
in |
Instance const &
|
UpdateInstanceRequestBuilder(google::spanner::admin::instance::v1::Instance)
It's particularly useful if you want to add some labels to existing instances.
Parameter |
Name |
Description |
in |
google::spanner::admin::instance::v1::Instance
|
Operators
operator=(UpdateInstanceRequestBuilder const &)
Parameter |
Name |
Description |
|
UpdateInstanceRequestBuilder const &
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
operator=(UpdateInstanceRequestBuilder &&)
Parameter |
Name |
Description |
|
UpdateInstanceRequestBuilder &&
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
Functions
SetName(std::string) &
Parameter |
Name |
Description |
name |
std::string
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
SetName(std::string) &&
Parameter |
Name |
Description |
name |
std::string
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder && |
|
SetDisplayName(std::string) &
Parameter |
Name |
Description |
display_name |
std::string
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
SetDisplayName(std::string) &&
Parameter |
Name |
Description |
display_name |
std::string
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder && |
|
SetNodeCount(int) &
Parameter |
Name |
Description |
node_count |
int
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
SetNodeCount(int) &&
Parameter |
Name |
Description |
node_count |
int
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder && |
|
SetProcessingUnits(int) &
Parameter |
Name |
Description |
processing_units |
int
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
SetProcessingUnits(int) &&
Parameter |
Name |
Description |
processing_units |
int
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder && |
|
AddLabels(std::map< std::string, std::string > const &) &
Parameter |
Name |
Description |
labels |
std::map< std::string, std::string > const &
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
AddLabels(std::map< std::string, std::string > const &) &&
Parameter |
Name |
Description |
labels |
std::map< std::string, std::string > const &
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder && |
|
SetLabels(std::map< std::string, std::string > const &) &
Parameter |
Name |
Description |
labels |
std::map< std::string, std::string > const &
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder & |
|
SetLabels(std::map< std::string, std::string > const &) &&
Parameter |
Name |
Description |
labels |
std::map< std::string, std::string > const &
|
Returns |
Type |
Description |
UpdateInstanceRequestBuilder && |
|
Build() &
Returns |
Type |
Description |
google::spanner::admin::instance::v1::UpdateInstanceRequest & |
|
Build() &&
Returns |
Type |
Description |
google::spanner::admin::instance::v1::UpdateInstanceRequest && |
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-08-10 UTC.
[{
"type": "thumb-down",
"id": "hardToUnderstand",
"label":"Hard to understand"
},{
"type": "thumb-down",
"id": "incorrectInformationOrSampleCode",
"label":"Incorrect information or sample code"
},{
"type": "thumb-down",
"id": "missingTheInformationSamplesINeed",
"label":"Missing the information/samples I need"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
{
"last_modified": "Last updated 2024-08-10 UTC.",
"state": ""
}