Struct aws_sdk_dynamodb::model::replica_global_secondary_index_auto_scaling_description::Builder
source · pub struct Builder { /* private fields */ }
Expand description
A builder for ReplicaGlobalSecondaryIndexAutoScalingDescription
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn index_name(self, input: impl Into<String>) -> Self
pub fn index_name(self, input: impl Into<String>) -> Self
The name of the global secondary index.
sourcepub fn set_index_name(self, input: Option<String>) -> Self
pub fn set_index_name(self, input: Option<String>) -> Self
The name of the global secondary index.
Examples found in repository?
12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185
pub(crate) fn deser_structure_crate_model_replica_global_secondary_index_auto_scaling_description<
'a,
I,
>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::ReplicaGlobalSecondaryIndexAutoScalingDescription>,
aws_smithy_json::deserialize::error::DeserializeError,
>
where
I: Iterator<
Item = Result<
aws_smithy_json::deserialize::Token<'a>,
aws_smithy_json::deserialize::error::DeserializeError,
>,
>,
{
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
Some(aws_smithy_json::deserialize::Token::StartObject { .. }) => {
#[allow(unused_mut)]let mut builder = crate::model::replica_global_secondary_index_auto_scaling_description::Builder::default();
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"IndexName" => {
builder = builder.set_index_name(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| s.to_unescaped().map(|u| u.into_owned()))
.transpose()?,
);
}
"IndexStatus" => {
builder = builder.set_index_status(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped()
.map(|u| crate::model::IndexStatus::from(u.as_ref()))
})
.transpose()?,
);
}
"ProvisionedReadCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_read_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
"ProvisionedWriteCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_write_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
Ok(Some(builder.build()))
}
_ => Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"expected start object or null",
),
),
}
}
sourcepub fn index_status(self, input: IndexStatus) -> Self
pub fn index_status(self, input: IndexStatus) -> Self
The current state of the replica global secondary index:
-
CREATING
- The index is being created. -
UPDATING
- The index is being updated. -
DELETING
- The index is being deleted. -
ACTIVE
- The index is ready for use.
sourcepub fn set_index_status(self, input: Option<IndexStatus>) -> Self
pub fn set_index_status(self, input: Option<IndexStatus>) -> Self
The current state of the replica global secondary index:
-
CREATING
- The index is being created. -
UPDATING
- The index is being updated. -
DELETING
- The index is being deleted. -
ACTIVE
- The index is ready for use.
Examples found in repository?
12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185
pub(crate) fn deser_structure_crate_model_replica_global_secondary_index_auto_scaling_description<
'a,
I,
>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::ReplicaGlobalSecondaryIndexAutoScalingDescription>,
aws_smithy_json::deserialize::error::DeserializeError,
>
where
I: Iterator<
Item = Result<
aws_smithy_json::deserialize::Token<'a>,
aws_smithy_json::deserialize::error::DeserializeError,
>,
>,
{
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
Some(aws_smithy_json::deserialize::Token::StartObject { .. }) => {
#[allow(unused_mut)]let mut builder = crate::model::replica_global_secondary_index_auto_scaling_description::Builder::default();
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"IndexName" => {
builder = builder.set_index_name(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| s.to_unescaped().map(|u| u.into_owned()))
.transpose()?,
);
}
"IndexStatus" => {
builder = builder.set_index_status(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped()
.map(|u| crate::model::IndexStatus::from(u.as_ref()))
})
.transpose()?,
);
}
"ProvisionedReadCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_read_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
"ProvisionedWriteCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_write_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
Ok(Some(builder.build()))
}
_ => Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"expected start object or null",
),
),
}
}
sourcepub fn provisioned_read_capacity_auto_scaling_settings(
self,
input: AutoScalingSettingsDescription
) -> Self
pub fn provisioned_read_capacity_auto_scaling_settings(
self,
input: AutoScalingSettingsDescription
) -> Self
Represents the auto scaling settings for a global table or global secondary index.
sourcepub fn set_provisioned_read_capacity_auto_scaling_settings(
self,
input: Option<AutoScalingSettingsDescription>
) -> Self
pub fn set_provisioned_read_capacity_auto_scaling_settings(
self,
input: Option<AutoScalingSettingsDescription>
) -> Self
Represents the auto scaling settings for a global table or global secondary index.
Examples found in repository?
12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185
pub(crate) fn deser_structure_crate_model_replica_global_secondary_index_auto_scaling_description<
'a,
I,
>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::ReplicaGlobalSecondaryIndexAutoScalingDescription>,
aws_smithy_json::deserialize::error::DeserializeError,
>
where
I: Iterator<
Item = Result<
aws_smithy_json::deserialize::Token<'a>,
aws_smithy_json::deserialize::error::DeserializeError,
>,
>,
{
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
Some(aws_smithy_json::deserialize::Token::StartObject { .. }) => {
#[allow(unused_mut)]let mut builder = crate::model::replica_global_secondary_index_auto_scaling_description::Builder::default();
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"IndexName" => {
builder = builder.set_index_name(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| s.to_unescaped().map(|u| u.into_owned()))
.transpose()?,
);
}
"IndexStatus" => {
builder = builder.set_index_status(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped()
.map(|u| crate::model::IndexStatus::from(u.as_ref()))
})
.transpose()?,
);
}
"ProvisionedReadCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_read_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
"ProvisionedWriteCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_write_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
Ok(Some(builder.build()))
}
_ => Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"expected start object or null",
),
),
}
}
sourcepub fn provisioned_write_capacity_auto_scaling_settings(
self,
input: AutoScalingSettingsDescription
) -> Self
pub fn provisioned_write_capacity_auto_scaling_settings(
self,
input: AutoScalingSettingsDescription
) -> Self
Represents the auto scaling settings for a global table or global secondary index.
sourcepub fn set_provisioned_write_capacity_auto_scaling_settings(
self,
input: Option<AutoScalingSettingsDescription>
) -> Self
pub fn set_provisioned_write_capacity_auto_scaling_settings(
self,
input: Option<AutoScalingSettingsDescription>
) -> Self
Represents the auto scaling settings for a global table or global secondary index.
Examples found in repository?
12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185
pub(crate) fn deser_structure_crate_model_replica_global_secondary_index_auto_scaling_description<
'a,
I,
>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::ReplicaGlobalSecondaryIndexAutoScalingDescription>,
aws_smithy_json::deserialize::error::DeserializeError,
>
where
I: Iterator<
Item = Result<
aws_smithy_json::deserialize::Token<'a>,
aws_smithy_json::deserialize::error::DeserializeError,
>,
>,
{
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
Some(aws_smithy_json::deserialize::Token::StartObject { .. }) => {
#[allow(unused_mut)]let mut builder = crate::model::replica_global_secondary_index_auto_scaling_description::Builder::default();
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"IndexName" => {
builder = builder.set_index_name(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| s.to_unescaped().map(|u| u.into_owned()))
.transpose()?,
);
}
"IndexStatus" => {
builder = builder.set_index_status(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped()
.map(|u| crate::model::IndexStatus::from(u.as_ref()))
})
.transpose()?,
);
}
"ProvisionedReadCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_read_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
"ProvisionedWriteCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_write_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
Ok(Some(builder.build()))
}
_ => Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"expected start object or null",
),
),
}
}
sourcepub fn build(self) -> ReplicaGlobalSecondaryIndexAutoScalingDescription
pub fn build(self) -> ReplicaGlobalSecondaryIndexAutoScalingDescription
Consumes the builder and constructs a ReplicaGlobalSecondaryIndexAutoScalingDescription
.
Examples found in repository?
12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185
pub(crate) fn deser_structure_crate_model_replica_global_secondary_index_auto_scaling_description<
'a,
I,
>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::ReplicaGlobalSecondaryIndexAutoScalingDescription>,
aws_smithy_json::deserialize::error::DeserializeError,
>
where
I: Iterator<
Item = Result<
aws_smithy_json::deserialize::Token<'a>,
aws_smithy_json::deserialize::error::DeserializeError,
>,
>,
{
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
Some(aws_smithy_json::deserialize::Token::StartObject { .. }) => {
#[allow(unused_mut)]let mut builder = crate::model::replica_global_secondary_index_auto_scaling_description::Builder::default();
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"IndexName" => {
builder = builder.set_index_name(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| s.to_unescaped().map(|u| u.into_owned()))
.transpose()?,
);
}
"IndexStatus" => {
builder = builder.set_index_status(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped()
.map(|u| crate::model::IndexStatus::from(u.as_ref()))
})
.transpose()?,
);
}
"ProvisionedReadCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_read_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
"ProvisionedWriteCapacityAutoScalingSettings" => {
builder = builder.set_provisioned_write_capacity_auto_scaling_settings(
crate::json_deser::deser_structure_crate_model_auto_scaling_settings_description(tokens)?
);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
Ok(Some(builder.build()))
}
_ => Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"expected start object or null",
),
),
}
}