pub struct Builder { /* private fields */ }
Expand description

A builder for GetNetworkTelemetryInput.

Implementations§

The ID of the global network.

Examples found in repository?
src/client.rs (line 7125)
7124
7125
7126
7127
        pub fn global_network_id(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.global_network_id(input.into());
            self
        }

The ID of the global network.

Examples found in repository?
src/client.rs (line 7133)
7129
7130
7131
7132
7133
7134
7135
        pub fn set_global_network_id(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_global_network_id(input);
            self
        }

The ID of a core network.

Examples found in repository?
src/client.rs (line 7138)
7137
7138
7139
7140
        pub fn core_network_id(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.core_network_id(input.into());
            self
        }

The ID of a core network.

Examples found in repository?
src/client.rs (line 7146)
7142
7143
7144
7145
7146
7147
7148
        pub fn set_core_network_id(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_core_network_id(input);
            self
        }

The ARN of the gateway.

Examples found in repository?
src/client.rs (line 7151)
7150
7151
7152
7153
        pub fn registered_gateway_arn(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.registered_gateway_arn(input.into());
            self
        }

The ARN of the gateway.

Examples found in repository?
src/client.rs (line 7159)
7155
7156
7157
7158
7159
7160
7161
        pub fn set_registered_gateway_arn(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_registered_gateway_arn(input);
            self
        }

The Amazon Web Services Region.

Examples found in repository?
src/client.rs (line 7164)
7163
7164
7165
7166
        pub fn aws_region(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.aws_region(input.into());
            self
        }

The Amazon Web Services Region.

Examples found in repository?
src/client.rs (line 7169)
7168
7169
7170
7171
        pub fn set_aws_region(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_aws_region(input);
            self
        }

The Amazon Web Services account ID.

Examples found in repository?
src/client.rs (line 7174)
7173
7174
7175
7176
        pub fn account_id(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.account_id(input.into());
            self
        }

The Amazon Web Services account ID.

Examples found in repository?
src/client.rs (line 7179)
7178
7179
7180
7181
        pub fn set_account_id(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_account_id(input);
            self
        }

The resource type.

The following are the supported resource types for Direct Connect:

  • dxcon

  • dx-gateway

  • dx-vif

The following are the supported resource types for Network Manager:

  • connection

  • device

  • link

  • site

The following are the supported resource types for Amazon VPC:

  • customer-gateway

  • transit-gateway

  • transit-gateway-attachment

  • transit-gateway-connect-peer

  • transit-gateway-route-table

  • vpn-connection

Examples found in repository?
src/client.rs (line 7206)
7205
7206
7207
7208
        pub fn resource_type(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.resource_type(input.into());
            self
        }

The resource type.

The following are the supported resource types for Direct Connect:

  • dxcon

  • dx-gateway

  • dx-vif

The following are the supported resource types for Network Manager:

  • connection

  • device

  • link

  • site

The following are the supported resource types for Amazon VPC:

  • customer-gateway

  • transit-gateway

  • transit-gateway-attachment

  • transit-gateway-connect-peer

  • transit-gateway-route-table

  • vpn-connection

Examples found in repository?
src/client.rs (line 7236)
7232
7233
7234
7235
7236
7237
7238
        pub fn set_resource_type(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_resource_type(input);
            self
        }

The ARN of the resource.

Examples found in repository?
src/client.rs (line 7241)
7240
7241
7242
7243
        pub fn resource_arn(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.resource_arn(input.into());
            self
        }

The ARN of the resource.

Examples found in repository?
src/client.rs (line 7246)
7245
7246
7247
7248
        pub fn set_resource_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_resource_arn(input);
            self
        }

The maximum number of results to return.

Examples found in repository?
src/client.rs (line 7251)
7250
7251
7252
7253
        pub fn max_results(mut self, input: i32) -> Self {
            self.inner = self.inner.max_results(input);
            self
        }

The maximum number of results to return.

Examples found in repository?
src/client.rs (line 7256)
7255
7256
7257
7258
        pub fn set_max_results(mut self, input: std::option::Option<i32>) -> Self {
            self.inner = self.inner.set_max_results(input);
            self
        }

The token for the next page of results.

Examples found in repository?
src/client.rs (line 7261)
7260
7261
7262
7263
        pub fn next_token(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.next_token(input.into());
            self
        }

The token for the next page of results.

Examples found in repository?
src/client.rs (line 7266)
7265
7266
7267
7268
        pub fn set_next_token(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_next_token(input);
            self
        }

Consumes the builder and constructs a GetNetworkTelemetryInput.

Examples found in repository?
src/client.rs (line 7086)
7074
7075
7076
7077
7078
7079
7080
7081
7082
7083
7084
7085
7086
7087
7088
7089
7090
7091
7092
7093
7094
7095
7096
7097
7098
7099
7100
7101
7102
7103
7104
7105
7106
7107
7108
7109
7110
7111
7112
7113
7114
7115
7116
        pub async fn customize(
            self,
        ) -> std::result::Result<
            crate::operation::customize::CustomizableOperation<
                crate::operation::GetNetworkTelemetry,
                aws_http::retry::AwsResponseRetryClassifier,
            >,
            aws_smithy_http::result::SdkError<crate::error::GetNetworkTelemetryError>,
        > {
            let handle = self.handle.clone();
            let operation = self
                .inner
                .build()
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?
                .make_operation(&handle.conf)
                .await
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?;
            Ok(crate::operation::customize::CustomizableOperation { handle, operation })
        }

        /// Sends the request and returns the response.
        ///
        /// If an error occurs, an `SdkError` will be returned with additional details that
        /// can be matched against.
        ///
        /// By default, any retryable failures will be retried twice. Retry behavior
        /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
        /// set when configuring the client.
        pub async fn send(
            self,
        ) -> std::result::Result<
            crate::output::GetNetworkTelemetryOutput,
            aws_smithy_http::result::SdkError<crate::error::GetNetworkTelemetryError>,
        > {
            let op = self
                .inner
                .build()
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?
                .make_operation(&self.handle.conf)
                .await
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?;
            self.handle.client.call(op).await
        }
More examples
Hide additional examples
src/paginator.rs (line 1484)
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
    pub fn send(
        self,
    ) -> impl tokio_stream::Stream<
        Item = std::result::Result<
            crate::output::GetNetworkTelemetryOutput,
            aws_smithy_http::result::SdkError<crate::error::GetNetworkTelemetryError>,
        >,
    > + Unpin {
        // Move individual fields out of self for the borrow checker
        let builder = self.builder;
        let handle = self.handle;
        aws_smithy_async::future::fn_stream::FnStream::new(move |tx| {
            Box::pin(async move {
                // Build the input for the first time. If required fields are missing, this is where we'll produce an early error.
                let mut input = match builder
                    .build()
                    .map_err(aws_smithy_http::result::SdkError::construction_failure)
                {
                    Ok(input) => input,
                    Err(e) => {
                        let _ = tx.send(Err(e)).await;
                        return;
                    }
                };
                loop {
                    let op = match input
                        .make_operation(&handle.conf)
                        .await
                        .map_err(aws_smithy_http::result::SdkError::construction_failure)
                    {
                        Ok(op) => op,
                        Err(e) => {
                            let _ = tx.send(Err(e)).await;
                            return;
                        }
                    };
                    let resp = handle.client.call(op).await;
                    // If the input member is None or it was an error
                    let done = match resp {
                        Ok(ref resp) => {
                            let new_token = crate::lens::reflens_structure_crate_output_get_network_telemetry_output_next_token(resp);
                            let is_empty = new_token.map(|token| token.is_empty()).unwrap_or(true);
                            if !is_empty
                                && new_token == input.next_token.as_ref()
                                && self.stop_on_duplicate_token
                            {
                                true
                            } else {
                                input.next_token = new_token.cloned();
                                is_empty
                            }
                        }
                        Err(_) => true,
                    };
                    if tx.send(resp).await.is_err() {
                        // receiving end was dropped
                        return;
                    }
                    if done {
                        return;
                    }
                }
            })
        })
    }

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more