pub struct Builder { /* private fields */ }Expand description
A builder for RouteAnalysisCompletion.
Implementations§
source§impl Builder
impl Builder
sourcepub fn result_code(self, input: RouteAnalysisCompletionResultCode) -> Self
pub fn result_code(self, input: RouteAnalysisCompletionResultCode) -> Self
The result of the analysis. If the status is NOT_CONNECTED, check the reason code.
sourcepub fn set_result_code(
self,
input: Option<RouteAnalysisCompletionResultCode>
) -> Self
pub fn set_result_code(
self,
input: Option<RouteAnalysisCompletionResultCode>
) -> Self
The result of the analysis. If the status is NOT_CONNECTED, check the reason code.
Examples found in repository?
10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671
pub(crate) fn deser_structure_crate_model_route_analysis_completion<'a, I>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::RouteAnalysisCompletion>,
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::route_analysis_completion::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() {
"ResultCode" => {
builder = builder.set_result_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionResultCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonCode" => {
builder = builder.set_reason_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionReasonCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonContext" => {
builder = builder.set_reason_context(
crate::json_deser::deser_map_com_amazonaws_networkmanager_reason_context_map(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 reason_code(self, input: RouteAnalysisCompletionReasonCode) -> Self
pub fn reason_code(self, input: RouteAnalysisCompletionReasonCode) -> Self
The reason code. Available only if a connection is not found.
-
BLACKHOLE_ROUTE_FOR_DESTINATION_FOUND- Found a black hole route with the destination CIDR block. -
CYCLIC_PATH_DETECTED- Found the same resource multiple times while traversing the path. -
INACTIVE_ROUTE_FOR_DESTINATION_FOUND- Found an inactive route with the destination CIDR block. -
MAX_HOPS_EXCEEDED- Analysis exceeded 64 hops without finding the destination. -
ROUTE_NOT_FOUND- Cannot find a route table with the destination CIDR block. -
TGW_ATTACH_ARN_NO_MATCH- Found an attachment, but not with the correct destination ARN. -
TGW_ATTACH_NOT_FOUND- Cannot find an attachment. -
TGW_ATTACH_NOT_IN_TGW- Found an attachment, but not to the correct transit gateway. -
TGW_ATTACH_STABLE_ROUTE_TABLE_NOT_FOUND- The state of the route table association is not associated.
sourcepub fn set_reason_code(
self,
input: Option<RouteAnalysisCompletionReasonCode>
) -> Self
pub fn set_reason_code(
self,
input: Option<RouteAnalysisCompletionReasonCode>
) -> Self
The reason code. Available only if a connection is not found.
-
BLACKHOLE_ROUTE_FOR_DESTINATION_FOUND- Found a black hole route with the destination CIDR block. -
CYCLIC_PATH_DETECTED- Found the same resource multiple times while traversing the path. -
INACTIVE_ROUTE_FOR_DESTINATION_FOUND- Found an inactive route with the destination CIDR block. -
MAX_HOPS_EXCEEDED- Analysis exceeded 64 hops without finding the destination. -
ROUTE_NOT_FOUND- Cannot find a route table with the destination CIDR block. -
TGW_ATTACH_ARN_NO_MATCH- Found an attachment, but not with the correct destination ARN. -
TGW_ATTACH_NOT_FOUND- Cannot find an attachment. -
TGW_ATTACH_NOT_IN_TGW- Found an attachment, but not to the correct transit gateway. -
TGW_ATTACH_STABLE_ROUTE_TABLE_NOT_FOUND- The state of the route table association is not associated.
Examples found in repository?
10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671
pub(crate) fn deser_structure_crate_model_route_analysis_completion<'a, I>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::RouteAnalysisCompletion>,
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::route_analysis_completion::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() {
"ResultCode" => {
builder = builder.set_result_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionResultCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonCode" => {
builder = builder.set_reason_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionReasonCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonContext" => {
builder = builder.set_reason_context(
crate::json_deser::deser_map_com_amazonaws_networkmanager_reason_context_map(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 reason_context(self, k: impl Into<String>, v: impl Into<String>) -> Self
pub fn reason_context(self, k: impl Into<String>, v: impl Into<String>) -> Self
Adds a key-value pair to reason_context.
To override the contents of this collection use set_reason_context.
Additional information about the path. Available only if a connection is not found.
sourcepub fn set_reason_context(self, input: Option<HashMap<String, String>>) -> Self
pub fn set_reason_context(self, input: Option<HashMap<String, String>>) -> Self
Additional information about the path. Available only if a connection is not found.
Examples found in repository?
10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671
pub(crate) fn deser_structure_crate_model_route_analysis_completion<'a, I>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::RouteAnalysisCompletion>,
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::route_analysis_completion::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() {
"ResultCode" => {
builder = builder.set_result_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionResultCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonCode" => {
builder = builder.set_reason_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionReasonCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonContext" => {
builder = builder.set_reason_context(
crate::json_deser::deser_map_com_amazonaws_networkmanager_reason_context_map(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) -> RouteAnalysisCompletion
pub fn build(self) -> RouteAnalysisCompletion
Consumes the builder and constructs a RouteAnalysisCompletion.
Examples found in repository?
10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671
pub(crate) fn deser_structure_crate_model_route_analysis_completion<'a, I>(
tokens: &mut std::iter::Peekable<I>,
) -> Result<
Option<crate::model::RouteAnalysisCompletion>,
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::route_analysis_completion::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() {
"ResultCode" => {
builder = builder.set_result_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionResultCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonCode" => {
builder = builder.set_reason_code(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| {
s.to_unescaped().map(|u| {
crate::model::RouteAnalysisCompletionReasonCode::from(
u.as_ref(),
)
})
})
.transpose()?,
);
}
"ReasonContext" => {
builder = builder.set_reason_context(
crate::json_deser::deser_map_com_amazonaws_networkmanager_reason_context_map(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",
),
),
}
}