Client Test

Client Test

rev. dfb5149b65b7bcc09edd15b8e071ad43b5ac5943

Files changed:

tmp-codegen-diff/codegen-client-test/ebs/rust-client-codegen/src/operation/list_snapshot_blocks/_list_snapshot_blocks_input.rs

@@ -1,1 +119,198 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct ListSnapshotBlocksInput {
    6         -
    /// <p>The number of results to return.</p>
           8  +
pub /* StructureGenerator.kt:201 */ struct ListSnapshotBlocksInput {
           9  +
    /// /* StructureGenerator.kt:231 */<p>The number of results to return.</p>
    7     10   
    pub max_results: ::std::option::Option<i32>,
    8         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
          11  +
    /// /* StructureGenerator.kt:231 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
    9     12   
    pub starting_block_index: ::std::option::Option<i32>,
   10         -
    /// <p>The token to request the next page of results.</p>
          13  +
    /// /* StructureGenerator.kt:231 */<p>The token to request the next page of results.</p>
   11     14   
    pub next_token: ::std::option::Option<::std::string::String>,
   12         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
          15  +
    /// /* StructureGenerator.kt:231 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
   13     16   
    pub snapshot_id: ::std::option::Option<::std::string::String>,
          17  +
    /* StructureGenerator.kt:201 */
   14     18   
}
          19  +
/* StructureGenerator.kt:135 */
   15     20   
impl ListSnapshotBlocksInput {
   16         -
    /// <p>The number of results to return.</p>
          21  +
    /// /* StructureGenerator.kt:231 */<p>The number of results to return.</p>
          22  +
    /* StructureGenerator.kt:166 */
   17     23   
    pub fn max_results(&self) -> ::std::option::Option<i32> {
          24  +
        /* StructureGenerator.kt:168 */
   18     25   
        self.max_results
          26  +
        /* StructureGenerator.kt:166 */
   19     27   
    }
   20         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
          28  +
    /// /* StructureGenerator.kt:231 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
          29  +
    /* StructureGenerator.kt:166 */
   21     30   
    pub fn starting_block_index(&self) -> ::std::option::Option<i32> {
          31  +
        /* StructureGenerator.kt:168 */
   22     32   
        self.starting_block_index
          33  +
        /* StructureGenerator.kt:166 */
   23     34   
    }
   24         -
    /// <p>The token to request the next page of results.</p>
          35  +
    /// /* StructureGenerator.kt:231 */<p>The token to request the next page of results.</p>
          36  +
    /* StructureGenerator.kt:166 */
   25     37   
    pub fn next_token(&self) -> ::std::option::Option<&str> {
          38  +
        /* StructureGenerator.kt:169 */
   26     39   
        self.next_token.as_deref()
          40  +
        /* StructureGenerator.kt:166 */
   27     41   
    }
   28         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
          42  +
    /// /* StructureGenerator.kt:231 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
          43  +
    /* StructureGenerator.kt:166 */
   29     44   
    pub fn snapshot_id(&self) -> ::std::option::Option<&str> {
          45  +
        /* StructureGenerator.kt:169 */
   30     46   
        self.snapshot_id.as_deref()
          47  +
        /* StructureGenerator.kt:166 */
   31     48   
    }
          49  +
    /* StructureGenerator.kt:135 */
   32     50   
}
          51  +
/* ClientCodegenVisitor.kt:237 */
   33     52   
impl ListSnapshotBlocksInput {
   34         -
    /// Creates a new builder-style object to manufacture [`ListSnapshotBlocksInput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput).
          53  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`ListSnapshotBlocksInput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput).
          54  +
    /* BuilderGenerator.kt:175 */
   35     55   
    pub fn builder() -> crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksInputBuilder {
          56  +
        /* BuilderGenerator.kt:176 */
   36     57   
        crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksInputBuilder::default()
          58  +
        /* BuilderGenerator.kt:175 */
   37     59   
    }
          60  +
    /* ClientCodegenVisitor.kt:237 */
   38     61   
}
   39     62   
   40         -
/// A builder for [`ListSnapshotBlocksInput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput).
          63  +
/// /* BuilderGenerator.kt:342 */A builder for [`ListSnapshotBlocksInput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput).
          64  +
/* RustType.kt:516 */
   41     65   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          66  +
/* RustType.kt:516 */
   42     67   
#[non_exhaustive]
          68  +
/* BuilderGenerator.kt:345 */
   43     69   
pub struct ListSnapshotBlocksInputBuilder {
   44         -
    pub(crate) max_results: ::std::option::Option<i32>,
   45         -
    pub(crate) starting_block_index: ::std::option::Option<i32>,
   46         -
    pub(crate) next_token: ::std::option::Option<::std::string::String>,
   47         -
    pub(crate) snapshot_id: ::std::option::Option<::std::string::String>,
          70  +
    /* BuilderGenerator.kt:275 */ pub(crate) max_results: ::std::option::Option<i32>,
          71  +
    /* BuilderGenerator.kt:275 */ pub(crate) starting_block_index: ::std::option::Option<i32>,
          72  +
    /* BuilderGenerator.kt:275 */ pub(crate) next_token: ::std::option::Option<::std::string::String>,
          73  +
    /* BuilderGenerator.kt:275 */ pub(crate) snapshot_id: ::std::option::Option<::std::string::String>,
          74  +
    /* BuilderGenerator.kt:345 */
   48     75   
}
          76  +
/* BuilderGenerator.kt:355 */
   49     77   
impl ListSnapshotBlocksInputBuilder {
   50         -
    /// <p>The number of results to return.</p>
          78  +
    /// /* BuilderGenerator.kt:286 */<p>The number of results to return.</p>
          79  +
    /* BuilderGenerator.kt:291 */
   51     80   
    pub fn max_results(mut self, input: i32) -> Self {
          81  +
        /* BuilderGenerator.kt:292 */
   52     82   
        self.max_results = ::std::option::Option::Some(input);
          83  +
        /* BuilderGenerator.kt:293 */
   53     84   
        self
          85  +
        /* BuilderGenerator.kt:291 */
   54     86   
    }
   55         -
    /// <p>The number of results to return.</p>
          87  +
    /// /* BuilderGenerator.kt:312 */<p>The number of results to return.</p>
          88  +
    /* BuilderGenerator.kt:314 */
   56     89   
    pub fn set_max_results(mut self, input: ::std::option::Option<i32>) -> Self {
          90  +
        /* BuilderGenerator.kt:315 */
   57     91   
        self.max_results = input;
   58     92   
        self
          93  +
        /* BuilderGenerator.kt:314 */
   59     94   
    }
   60         -
    /// <p>The number of results to return.</p>
          95  +
    /// /* BuilderGenerator.kt:334 */<p>The number of results to return.</p>
          96  +
    /* BuilderGenerator.kt:336 */
   61     97   
    pub fn get_max_results(&self) -> &::std::option::Option<i32> {
          98  +
        /* BuilderGenerator.kt:337 */
   62     99   
        &self.max_results
         100  +
        /* BuilderGenerator.kt:336 */
   63    101   
    }
   64         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         102  +
    /// /* BuilderGenerator.kt:286 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         103  +
    /* BuilderGenerator.kt:291 */
   65    104   
    pub fn starting_block_index(mut self, input: i32) -> Self {
         105  +
        /* BuilderGenerator.kt:292 */
   66    106   
        self.starting_block_index = ::std::option::Option::Some(input);
         107  +
        /* BuilderGenerator.kt:293 */
   67    108   
        self
         109  +
        /* BuilderGenerator.kt:291 */
   68    110   
    }
   69         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         111  +
    /// /* BuilderGenerator.kt:312 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         112  +
    /* BuilderGenerator.kt:314 */
   70    113   
    pub fn set_starting_block_index(mut self, input: ::std::option::Option<i32>) -> Self {
         114  +
        /* BuilderGenerator.kt:315 */
   71    115   
        self.starting_block_index = input;
   72    116   
        self
         117  +
        /* BuilderGenerator.kt:314 */
   73    118   
    }
   74         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         119  +
    /// /* BuilderGenerator.kt:334 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         120  +
    /* BuilderGenerator.kt:336 */
   75    121   
    pub fn get_starting_block_index(&self) -> &::std::option::Option<i32> {
         122  +
        /* BuilderGenerator.kt:337 */
   76    123   
        &self.starting_block_index
         124  +
        /* BuilderGenerator.kt:336 */
   77    125   
    }
   78         -
    /// <p>The token to request the next page of results.</p>
         126  +
    /// /* BuilderGenerator.kt:286 */<p>The token to request the next page of results.</p>
         127  +
    /* BuilderGenerator.kt:291 */
   79    128   
    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
         129  +
        /* BuilderGenerator.kt:292 */
   80    130   
        self.next_token = ::std::option::Option::Some(input.into());
         131  +
        /* BuilderGenerator.kt:293 */
   81    132   
        self
         133  +
        /* BuilderGenerator.kt:291 */
   82    134   
    }
   83         -
    /// <p>The token to request the next page of results.</p>
         135  +
    /// /* BuilderGenerator.kt:312 */<p>The token to request the next page of results.</p>
         136  +
    /* BuilderGenerator.kt:314 */
   84    137   
    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
         138  +
        /* BuilderGenerator.kt:315 */
   85    139   
        self.next_token = input;
   86    140   
        self
         141  +
        /* BuilderGenerator.kt:314 */
   87    142   
    }
   88         -
    /// <p>The token to request the next page of results.</p>
         143  +
    /// /* BuilderGenerator.kt:334 */<p>The token to request the next page of results.</p>
         144  +
    /* BuilderGenerator.kt:336 */
   89    145   
    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
         146  +
        /* BuilderGenerator.kt:337 */
   90    147   
        &self.next_token
         148  +
        /* BuilderGenerator.kt:336 */
   91    149   
    }
   92         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
   93         -
    /// This field is required.
         150  +
    /// /* BuilderGenerator.kt:286 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         151  +
    /// /* BuilderGenerator.kt:288 */This field is required.
         152  +
    /* BuilderGenerator.kt:291 */
   94    153   
    pub fn snapshot_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
         154  +
        /* BuilderGenerator.kt:292 */
   95    155   
        self.snapshot_id = ::std::option::Option::Some(input.into());
         156  +
        /* BuilderGenerator.kt:293 */
   96    157   
        self
         158  +
        /* BuilderGenerator.kt:291 */
   97    159   
    }
   98         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         160  +
    /// /* BuilderGenerator.kt:312 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         161  +
    /* BuilderGenerator.kt:314 */
   99    162   
    pub fn set_snapshot_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
         163  +
        /* BuilderGenerator.kt:315 */
  100    164   
        self.snapshot_id = input;
  101    165   
        self
         166  +
        /* BuilderGenerator.kt:314 */
  102    167   
    }
  103         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         168  +
    /// /* BuilderGenerator.kt:334 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         169  +
    /* BuilderGenerator.kt:336 */
  104    170   
    pub fn get_snapshot_id(&self) -> &::std::option::Option<::std::string::String> {
         171  +
        /* BuilderGenerator.kt:337 */
  105    172   
        &self.snapshot_id
         173  +
        /* BuilderGenerator.kt:336 */
  106    174   
    }
  107         -
    /// Consumes the builder and constructs a [`ListSnapshotBlocksInput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput).
         175  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`ListSnapshotBlocksInput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput).
         176  +
    /* BuilderGenerator.kt:253 */
  108    177   
    pub fn build(
  109    178   
        self,
  110    179   
    ) -> ::std::result::Result<crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput, ::aws_smithy_types::error::operation::BuildError>
  111    180   
    {
  112         -
        ::std::result::Result::Ok(crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput {
  113         -
            max_results: self.max_results,
  114         -
            starting_block_index: self.starting_block_index,
  115         -
            next_token: self.next_token,
  116         -
            snapshot_id: self.snapshot_id,
  117         -
        })
  118         -
    }
         181  +
        /* BuilderGenerator.kt:254 */
         182  +
        ::std::result::Result::Ok(
         183  +
            /* BuilderGenerator.kt:477 */
         184  +
            crate::operation::list_snapshot_blocks::ListSnapshotBlocksInput {
         185  +
                /* BuilderGenerator.kt:481 */ max_results: self.max_results,
         186  +
                /* BuilderGenerator.kt:481 */
         187  +
                starting_block_index: self.starting_block_index,
         188  +
                /* BuilderGenerator.kt:481 */
         189  +
                next_token: self.next_token,
         190  +
                /* BuilderGenerator.kt:481 */
         191  +
                snapshot_id: self.snapshot_id,
         192  +
                /* BuilderGenerator.kt:477 */
         193  +
            }, /* BuilderGenerator.kt:254 */
         194  +
        )
         195  +
        /* BuilderGenerator.kt:253 */
         196  +
    }
         197  +
    /* BuilderGenerator.kt:355 */
  119    198   
}

tmp-codegen-diff/codegen-client-test/ebs/rust-client-codegen/src/operation/list_snapshot_blocks/_list_snapshot_blocks_output.rs

@@ -1,1 +167,283 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq)]
    5         -
pub struct ListSnapshotBlocksOutput {
    6         -
    /// <p>The size of the volume in GB.</p>
           8  +
pub /* StructureGenerator.kt:201 */ struct ListSnapshotBlocksOutput {
           9  +
    /// /* StructureGenerator.kt:231 */<p>The size of the volume in GB.</p>
    7     10   
    pub volume_size: ::std::option::Option<i64>,
    8         -
    /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
          11  +
    /// /* StructureGenerator.kt:231 */<p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
    9     12   
    pub next_token: ::std::option::Option<::std::string::String>,
   10         -
    /// <p>The time when the <code>BlockToken</code> expires.</p>
          13  +
    /// /* StructureGenerator.kt:231 */<p>The time when the <code>BlockToken</code> expires.</p>
   11     14   
    pub expiry_time: ::std::option::Option<::aws_smithy_types::DateTime>,
   12         -
    /// <p>An array of objects containing information about the blocks.</p>
          15  +
    /// /* StructureGenerator.kt:231 */<p>An array of objects containing information about the blocks.</p>
   13     16   
    pub blocks: ::std::option::Option<::std::vec::Vec<crate::types::Block>>,
   14         -
    /// <p>The size of the block.</p>
          17  +
    /// /* StructureGenerator.kt:231 */<p>The size of the block.</p>
   15     18   
    pub block_size: ::std::option::Option<i32>,
          19  +
    /* StructureGenerator.kt:201 */
   16     20   
}
          21  +
/* StructureGenerator.kt:135 */
   17     22   
impl ListSnapshotBlocksOutput {
   18         -
    /// <p>The size of the volume in GB.</p>
          23  +
    /// /* StructureGenerator.kt:231 */<p>The size of the volume in GB.</p>
          24  +
    /* StructureGenerator.kt:166 */
   19     25   
    pub fn volume_size(&self) -> ::std::option::Option<i64> {
          26  +
        /* StructureGenerator.kt:168 */
   20     27   
        self.volume_size
          28  +
        /* StructureGenerator.kt:166 */
   21     29   
    }
   22         -
    /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
          30  +
    /// /* StructureGenerator.kt:231 */<p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
          31  +
    /* StructureGenerator.kt:166 */
   23     32   
    pub fn next_token(&self) -> ::std::option::Option<&str> {
          33  +
        /* StructureGenerator.kt:169 */
   24     34   
        self.next_token.as_deref()
          35  +
        /* StructureGenerator.kt:166 */
   25     36   
    }
   26         -
    /// <p>The time when the <code>BlockToken</code> expires.</p>
          37  +
    /// /* StructureGenerator.kt:231 */<p>The time when the <code>BlockToken</code> expires.</p>
          38  +
    /* StructureGenerator.kt:166 */
   27     39   
    pub fn expiry_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
          40  +
        /* StructureGenerator.kt:170 */
   28     41   
        self.expiry_time.as_ref()
          42  +
        /* StructureGenerator.kt:166 */
   29     43   
    }
   30         -
    /// <p>An array of objects containing information about the blocks.</p>
   31         -
    ///
   32         -
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.blocks.is_none()`.
          44  +
    /// /* StructureGenerator.kt:231 */<p>An array of objects containing information about the blocks.</p>
          45  +
    /// /* StructureGenerator.kt:162 */
          46  +
    /// /* StructureGenerator.kt:163 */If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.blocks.is_none()`.
          47  +
    /* StructureGenerator.kt:166 */
   33     48   
    pub fn blocks(&self) -> &[crate::types::Block] {
   34         -
        self.blocks.as_deref().unwrap_or_default()
          49  +
        /* StructureGenerator.kt:169 */
          50  +
        self.blocks
          51  +
            .as_deref()
          52  +
            /* StructureGenerator.kt:175 */
          53  +
            .unwrap_or_default()
          54  +
        /* StructureGenerator.kt:166 */
   35     55   
    }
   36         -
    /// <p>The size of the block.</p>
          56  +
    /// /* StructureGenerator.kt:231 */<p>The size of the block.</p>
          57  +
    /* StructureGenerator.kt:166 */
   37     58   
    pub fn block_size(&self) -> ::std::option::Option<i32> {
          59  +
        /* StructureGenerator.kt:168 */
   38     60   
        self.block_size
          61  +
        /* StructureGenerator.kt:166 */
   39     62   
    }
          63  +
    /* StructureGenerator.kt:135 */
   40     64   
}
          65  +
/* StructureGenerator.kt:101 */
   41     66   
impl ::std::fmt::Debug for ListSnapshotBlocksOutput {
          67  +
    /* StructureGenerator.kt:105 */
   42     68   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
          69  +
        /* StructureGenerator.kt:106 */
   43     70   
        let mut formatter = f.debug_struct("ListSnapshotBlocksOutput");
          71  +
        /* StructureGenerator.kt:121 */
   44     72   
        formatter.field("volume_size", &self.volume_size);
          73  +
        /* StructureGenerator.kt:121 */
   45     74   
        formatter.field("next_token", &self.next_token);
          75  +
        /* StructureGenerator.kt:121 */
   46     76   
        formatter.field("expiry_time", &self.expiry_time);
          77  +
        /* StructureGenerator.kt:121 */
   47     78   
        formatter.field("blocks", &"*** Sensitive Data Redacted ***");
          79  +
        /* StructureGenerator.kt:121 */
   48     80   
        formatter.field("block_size", &self.block_size);
          81  +
        /* StructureGenerator.kt:126 */
   49     82   
        formatter.finish()
          83  +
        /* StructureGenerator.kt:105 */
   50     84   
    }
          85  +
    /* StructureGenerator.kt:101 */
   51     86   
}
          87  +
/* ClientCodegenVisitor.kt:237 */
   52     88   
impl ListSnapshotBlocksOutput {
   53         -
    /// Creates a new builder-style object to manufacture [`ListSnapshotBlocksOutput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput).
          89  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`ListSnapshotBlocksOutput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput).
          90  +
    /* BuilderGenerator.kt:175 */
   54     91   
    pub fn builder() -> crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksOutputBuilder {
          92  +
        /* BuilderGenerator.kt:176 */
   55     93   
        crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksOutputBuilder::default()
          94  +
        /* BuilderGenerator.kt:175 */
   56     95   
    }
          96  +
    /* ClientCodegenVisitor.kt:237 */
   57     97   
}
   58     98   
   59         -
/// A builder for [`ListSnapshotBlocksOutput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput).
          99  +
/// /* BuilderGenerator.kt:342 */A builder for [`ListSnapshotBlocksOutput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput).
         100  +
/* RustType.kt:516 */
   60    101   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
         102  +
/* RustType.kt:516 */
   61    103   
#[non_exhaustive]
         104  +
/* BuilderGenerator.kt:345 */
   62    105   
pub struct ListSnapshotBlocksOutputBuilder {
   63         -
    pub(crate) volume_size: ::std::option::Option<i64>,
   64         -
    pub(crate) next_token: ::std::option::Option<::std::string::String>,
   65         -
    pub(crate) expiry_time: ::std::option::Option<::aws_smithy_types::DateTime>,
   66         -
    pub(crate) blocks: ::std::option::Option<::std::vec::Vec<crate::types::Block>>,
   67         -
    pub(crate) block_size: ::std::option::Option<i32>,
         106  +
    /* BuilderGenerator.kt:275 */ pub(crate) volume_size: ::std::option::Option<i64>,
         107  +
    /* BuilderGenerator.kt:275 */ pub(crate) next_token: ::std::option::Option<::std::string::String>,
         108  +
    /* BuilderGenerator.kt:275 */ pub(crate) expiry_time: ::std::option::Option<::aws_smithy_types::DateTime>,
         109  +
    /* BuilderGenerator.kt:275 */ pub(crate) blocks: ::std::option::Option<::std::vec::Vec<crate::types::Block>>,
         110  +
    /* BuilderGenerator.kt:275 */ pub(crate) block_size: ::std::option::Option<i32>,
         111  +
    /* BuilderGenerator.kt:345 */
   68    112   
}
         113  +
/* BuilderGenerator.kt:355 */
   69    114   
impl ListSnapshotBlocksOutputBuilder {
   70         -
    /// <p>The size of the volume in GB.</p>
         115  +
    /// /* BuilderGenerator.kt:286 */<p>The size of the volume in GB.</p>
         116  +
    /* BuilderGenerator.kt:291 */
   71    117   
    pub fn volume_size(mut self, input: i64) -> Self {
         118  +
        /* BuilderGenerator.kt:292 */
   72    119   
        self.volume_size = ::std::option::Option::Some(input);
         120  +
        /* BuilderGenerator.kt:293 */
   73    121   
        self
         122  +
        /* BuilderGenerator.kt:291 */
   74    123   
    }
   75         -
    /// <p>The size of the volume in GB.</p>
         124  +
    /// /* BuilderGenerator.kt:312 */<p>The size of the volume in GB.</p>
         125  +
    /* BuilderGenerator.kt:314 */
   76    126   
    pub fn set_volume_size(mut self, input: ::std::option::Option<i64>) -> Self {
         127  +
        /* BuilderGenerator.kt:315 */
   77    128   
        self.volume_size = input;
   78    129   
        self
         130  +
        /* BuilderGenerator.kt:314 */
   79    131   
    }
   80         -
    /// <p>The size of the volume in GB.</p>
         132  +
    /// /* BuilderGenerator.kt:334 */<p>The size of the volume in GB.</p>
         133  +
    /* BuilderGenerator.kt:336 */
   81    134   
    pub fn get_volume_size(&self) -> &::std::option::Option<i64> {
         135  +
        /* BuilderGenerator.kt:337 */
   82    136   
        &self.volume_size
         137  +
        /* BuilderGenerator.kt:336 */
   83    138   
    }
   84         -
    /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
         139  +
    /// /* BuilderGenerator.kt:286 */<p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
         140  +
    /* BuilderGenerator.kt:291 */
   85    141   
    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
         142  +
        /* BuilderGenerator.kt:292 */
   86    143   
        self.next_token = ::std::option::Option::Some(input.into());
         144  +
        /* BuilderGenerator.kt:293 */
   87    145   
        self
         146  +
        /* BuilderGenerator.kt:291 */
   88    147   
    }
   89         -
    /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
         148  +
    /// /* BuilderGenerator.kt:312 */<p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
         149  +
    /* BuilderGenerator.kt:314 */
   90    150   
    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
         151  +
        /* BuilderGenerator.kt:315 */
   91    152   
        self.next_token = input;
   92    153   
        self
         154  +
        /* BuilderGenerator.kt:314 */
   93    155   
    }
   94         -
    /// <p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
         156  +
    /// /* BuilderGenerator.kt:334 */<p>The token to use to retrieve the next page of results. This value is null when there are no more results to return.</p>
         157  +
    /* BuilderGenerator.kt:336 */
   95    158   
    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
         159  +
        /* BuilderGenerator.kt:337 */
   96    160   
        &self.next_token
         161  +
        /* BuilderGenerator.kt:336 */
   97    162   
    }
   98         -
    /// <p>The time when the <code>BlockToken</code> expires.</p>
         163  +
    /// /* BuilderGenerator.kt:286 */<p>The time when the <code>BlockToken</code> expires.</p>
         164  +
    /* BuilderGenerator.kt:291 */
   99    165   
    pub fn expiry_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
         166  +
        /* BuilderGenerator.kt:292 */
  100    167   
        self.expiry_time = ::std::option::Option::Some(input);
         168  +
        /* BuilderGenerator.kt:293 */
  101    169   
        self
         170  +
        /* BuilderGenerator.kt:291 */
  102    171   
    }
  103         -
    /// <p>The time when the <code>BlockToken</code> expires.</p>
         172  +
    /// /* BuilderGenerator.kt:312 */<p>The time when the <code>BlockToken</code> expires.</p>
         173  +
    /* BuilderGenerator.kt:314 */
  104    174   
    pub fn set_expiry_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
         175  +
        /* BuilderGenerator.kt:315 */
  105    176   
        self.expiry_time = input;
  106    177   
        self
         178  +
        /* BuilderGenerator.kt:314 */
  107    179   
    }
  108         -
    /// <p>The time when the <code>BlockToken</code> expires.</p>
         180  +
    /// /* BuilderGenerator.kt:334 */<p>The time when the <code>BlockToken</code> expires.</p>
         181  +
    /* BuilderGenerator.kt:336 */
  109    182   
    pub fn get_expiry_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
         183  +
        /* BuilderGenerator.kt:337 */
  110    184   
        &self.expiry_time
         185  +
        /* BuilderGenerator.kt:336 */
  111    186   
    }
  112         -
    /// Appends an item to `blocks`.
         187  +
    /// /* BuilderGenerator.kt:410 */Appends an item to `blocks`.
         188  +
    /* BuilderGenerator.kt:411 */
  113    189   
    ///
  114         -
    /// To override the contents of this collection use [`set_blocks`](Self::set_blocks).
         190  +
    /// /* BuilderGenerator.kt:412 */To override the contents of this collection use [`set_blocks`](Self::set_blocks).
         191  +
    /* BuilderGenerator.kt:413 */
  115    192   
    ///
  116         -
    /// <p>An array of objects containing information about the blocks.</p>
         193  +
    /// /* BuilderGenerator.kt:414 */<p>An array of objects containing information about the blocks.</p>
         194  +
    /* BuilderGenerator.kt:418 */
  117    195   
    pub fn blocks(mut self, input: crate::types::Block) -> Self {
         196  +
        /* BuilderGenerator.kt:419 */
  118    197   
        let mut v = self.blocks.unwrap_or_default();
  119    198   
        v.push(input);
  120    199   
        self.blocks = ::std::option::Option::Some(v);
  121    200   
        self
         201  +
        /* BuilderGenerator.kt:418 */
  122    202   
    }
  123         -
    /// <p>An array of objects containing information about the blocks.</p>
         203  +
    /// /* BuilderGenerator.kt:312 */<p>An array of objects containing information about the blocks.</p>
         204  +
    /* BuilderGenerator.kt:314 */
  124    205   
    pub fn set_blocks(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Block>>) -> Self {
         206  +
        /* BuilderGenerator.kt:315 */
  125    207   
        self.blocks = input;
  126    208   
        self
         209  +
        /* BuilderGenerator.kt:314 */
  127    210   
    }
  128         -
    /// <p>An array of objects containing information about the blocks.</p>
         211  +
    /// /* BuilderGenerator.kt:334 */<p>An array of objects containing information about the blocks.</p>
         212  +
    /* BuilderGenerator.kt:336 */
  129    213   
    pub fn get_blocks(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Block>> {
         214  +
        /* BuilderGenerator.kt:337 */
  130    215   
        &self.blocks
         216  +
        /* BuilderGenerator.kt:336 */
  131    217   
    }
  132         -
    /// <p>The size of the block.</p>
         218  +
    /// /* BuilderGenerator.kt:286 */<p>The size of the block.</p>
         219  +
    /* BuilderGenerator.kt:291 */
  133    220   
    pub fn block_size(mut self, input: i32) -> Self {
         221  +
        /* BuilderGenerator.kt:292 */
  134    222   
        self.block_size = ::std::option::Option::Some(input);
         223  +
        /* BuilderGenerator.kt:293 */
  135    224   
        self
         225  +
        /* BuilderGenerator.kt:291 */
  136    226   
    }
  137         -
    /// <p>The size of the block.</p>
         227  +
    /// /* BuilderGenerator.kt:312 */<p>The size of the block.</p>
         228  +
    /* BuilderGenerator.kt:314 */
  138    229   
    pub fn set_block_size(mut self, input: ::std::option::Option<i32>) -> Self {
         230  +
        /* BuilderGenerator.kt:315 */
  139    231   
        self.block_size = input;
  140    232   
        self
         233  +
        /* BuilderGenerator.kt:314 */
  141    234   
    }
  142         -
    /// <p>The size of the block.</p>
         235  +
    /// /* BuilderGenerator.kt:334 */<p>The size of the block.</p>
         236  +
    /* BuilderGenerator.kt:336 */
  143    237   
    pub fn get_block_size(&self) -> &::std::option::Option<i32> {
         238  +
        /* BuilderGenerator.kt:337 */
  144    239   
        &self.block_size
         240  +
        /* BuilderGenerator.kt:336 */
  145    241   
    }
  146         -
    /// Consumes the builder and constructs a [`ListSnapshotBlocksOutput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput).
         242  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`ListSnapshotBlocksOutput`](crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput).
         243  +
    /* BuilderGenerator.kt:253 */
  147    244   
    pub fn build(self) -> crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput {
         245  +
        /* BuilderGenerator.kt:477 */
  148    246   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput {
  149         -
            volume_size: self.volume_size,
         247  +
            /* BuilderGenerator.kt:481 */ volume_size: self.volume_size,
         248  +
            /* BuilderGenerator.kt:481 */
  150    249   
            next_token: self.next_token,
         250  +
            /* BuilderGenerator.kt:481 */
  151    251   
            expiry_time: self.expiry_time,
         252  +
            /* BuilderGenerator.kt:481 */
  152    253   
            blocks: self.blocks,
         254  +
            /* BuilderGenerator.kt:481 */
  153    255   
            block_size: self.block_size,
         256  +
            /* BuilderGenerator.kt:477 */
  154    257   
        }
         258  +
        /* BuilderGenerator.kt:253 */
  155    259   
    }
         260  +
    /* BuilderGenerator.kt:355 */
  156    261   
}
         262  +
/* BuilderGenerator.kt:379 */
  157    263   
impl ::std::fmt::Debug for ListSnapshotBlocksOutputBuilder {
         264  +
    /* BuilderGenerator.kt:380 */
  158    265   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         266  +
        /* BuilderGenerator.kt:381 */
  159    267   
        let mut formatter = f.debug_struct("ListSnapshotBlocksOutputBuilder");
         268  +
        /* BuilderGenerator.kt:395 */
  160    269   
        formatter.field("volume_size", &self.volume_size);
         270  +
        /* BuilderGenerator.kt:395 */
  161    271   
        formatter.field("next_token", &self.next_token);
         272  +
        /* BuilderGenerator.kt:395 */
  162    273   
        formatter.field("expiry_time", &self.expiry_time);
         274  +
        /* BuilderGenerator.kt:395 */
  163    275   
        formatter.field("blocks", &"*** Sensitive Data Redacted ***");
         276  +
        /* BuilderGenerator.kt:395 */
  164    277   
        formatter.field("block_size", &self.block_size);
         278  +
        /* BuilderGenerator.kt:400 */
  165    279   
        formatter.finish()
         280  +
        /* BuilderGenerator.kt:380 */
  166    281   
    }
         282  +
    /* BuilderGenerator.kt:379 */
  167    283   
}

tmp-codegen-diff/codegen-client-test/ebs/rust-client-codegen/src/operation/list_snapshot_blocks/builders.rs

@@ -1,1 +173,198 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CodegenDelegator.kt:255 */
    2      3   
pub use crate::operation::list_snapshot_blocks::_list_snapshot_blocks_output::ListSnapshotBlocksOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::list_snapshot_blocks::_list_snapshot_blocks_input::ListSnapshotBlocksInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksInputBuilder {
    7     10   
    /// Sends a request with this input using the given client.
    8     11   
    pub async fn send_with(
    9     12   
        self,
   10     13   
        client: &crate::Client,
   11     14   
    ) -> ::std::result::Result<
   12     15   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::list_snapshot_blocks::ListSnapshotBlocksError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.list_snapshot_blocks();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `ListSnapshotBlocks`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `ListSnapshotBlocks`.
   24     27   
///
   25         -
/// <p>Returns information about the blocks in an Amazon Elastic Block Store snapshot.</p>
          28  +
/// /* FluentBuilderGenerator.kt:130 */<p>Returns information about the blocks in an Amazon Elastic Block Store snapshot.</p>
          29  +
/* RustType.kt:516 */
   26     30   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          31  +
/* FluentBuilderGenerator.kt:270 */
   27     32   
pub struct ListSnapshotBlocksFluentBuilder {
   28     33   
    handle: ::std::sync::Arc<crate::client::Handle>,
   29     34   
    inner: crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksInputBuilder,
   30     35   
    config_override: ::std::option::Option<crate::config::Builder>,
   31     36   
}
          37  +
/* FluentBuilderGenerator.kt:381 */
   32     38   
impl
   33     39   
    crate::client::customize::internal::CustomizableSend<
   34     40   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput,
   35     41   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocksError,
   36     42   
    > for ListSnapshotBlocksFluentBuilder
   37     43   
{
   38     44   
    fn send(
   39     45   
        self,
   40     46   
        config_override: crate::config::Builder,
   41     47   
    ) -> crate::client::customize::internal::BoxFuture<
   42     48   
        crate::client::customize::internal::SendResult<
   43     49   
            crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput,
   44     50   
            crate::operation::list_snapshot_blocks::ListSnapshotBlocksError,
   45     51   
        >,
   46     52   
    > {
   47     53   
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
   48     54   
    }
   49     55   
}
          56  +
/* FluentBuilderGenerator.kt:282 */
   50     57   
impl ListSnapshotBlocksFluentBuilder {
          58  +
    /* FluentBuilderGenerator.kt:288 */
   51     59   
    /// Creates a new `ListSnapshotBlocksFluentBuilder`.
   52     60   
    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
   53     61   
        Self {
   54     62   
            handle,
   55     63   
            inner: ::std::default::Default::default(),
   56     64   
            config_override: ::std::option::Option::None,
   57     65   
        }
   58     66   
    }
          67  +
    /* FluentBuilderGenerator.kt:301 */
   59     68   
    /// Access the ListSnapshotBlocks as a reference.
   60     69   
    pub fn as_input(&self) -> &crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksInputBuilder {
   61     70   
        &self.inner
   62     71   
    }
          72  +
    /* FluentBuilderGenerator.kt:145 */
   63     73   
    /// Sends the request and returns the response.
   64     74   
    ///
   65     75   
    /// If an error occurs, an `SdkError` will be returned with additional details that
   66     76   
    /// can be matched against.
   67     77   
    ///
   68     78   
    /// By default, any retryable failures will be retried twice. Retry behavior
   69     79   
    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
   70     80   
    /// set when configuring the client.
   71     81   
    pub async fn send(
   72     82   
        self,
   73     83   
    ) -> ::std::result::Result<
   74     84   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput,
   75     85   
        ::aws_smithy_runtime_api::client::result::SdkError<
   76     86   
            crate::operation::list_snapshot_blocks::ListSnapshotBlocksError,
   77     87   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   78     88   
        >,
   79     89   
    > {
   80     90   
        let input = self
   81     91   
            .inner
   82     92   
            .build()
   83     93   
            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
   84     94   
        let runtime_plugins = crate::operation::list_snapshot_blocks::ListSnapshotBlocks::operation_runtime_plugins(
   85     95   
            self.handle.runtime_plugins.clone(),
   86     96   
            &self.handle.conf,
   87     97   
            self.config_override,
   88     98   
        );
   89     99   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocks::orchestrate(&runtime_plugins, input).await
   90    100   
    }
   91    101   
   92    102   
    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
   93    103   
    pub fn customize(
   94    104   
        self,
   95    105   
    ) -> crate::client::customize::CustomizableOperation<
   96    106   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocksOutput,
   97    107   
        crate::operation::list_snapshot_blocks::ListSnapshotBlocksError,
   98    108   
        Self,
   99    109   
    > {
  100    110   
        crate::client::customize::CustomizableOperation::new(self)
  101    111   
    }
         112  +
    /* FluentBuilderGenerator.kt:315 */
  102    113   
    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
  103    114   
        self.set_config_override(::std::option::Option::Some(config_override.into()));
  104    115   
        self
  105    116   
    }
  106    117   
  107    118   
    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
  108    119   
        self.config_override = config_override;
  109    120   
        self
  110    121   
    }
         122  +
    /* FluentBuilderGenerator.kt:340 */
  111    123   
    /// Create a paginator for this request
  112    124   
    ///
  113    125   
    /// Paginators are used by calling [`send().await`](crate::operation::list_snapshot_blocks::paginator::ListSnapshotBlocksPaginator::send) which returns a [`PaginationStream`](aws_smithy_async::future::pagination_stream::PaginationStream).
  114    126   
    pub fn into_paginator(self) -> crate::operation::list_snapshot_blocks::paginator::ListSnapshotBlocksPaginator {
  115    127   
        crate::operation::list_snapshot_blocks::paginator::ListSnapshotBlocksPaginator::new(self.handle, self.inner)
  116    128   
    }
  117         -
    /// <p>The number of results to return.</p>
         129  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The number of results to return.</p>
         130  +
    /* FluentBuilderGenerator.kt:500 */
  118    131   
    pub fn max_results(mut self, input: i32) -> Self {
  119    132   
        self.inner = self.inner.max_results(input);
  120    133   
        self
  121    134   
    }
  122         -
    /// <p>The number of results to return.</p>
         135  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The number of results to return.</p>
         136  +
    /* FluentBuilderGenerator.kt:500 */
  123    137   
    pub fn set_max_results(mut self, input: ::std::option::Option<i32>) -> Self {
  124    138   
        self.inner = self.inner.set_max_results(input);
  125    139   
        self
  126    140   
    }
  127         -
    /// <p>The number of results to return.</p>
         141  +
    /// /* FluentBuilderGenerator.kt:518 */<p>The number of results to return.</p>
         142  +
    /* FluentBuilderGenerator.kt:520 */
  128    143   
    pub fn get_max_results(&self) -> &::std::option::Option<i32> {
  129    144   
        self.inner.get_max_results()
  130    145   
    }
  131         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         146  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         147  +
    /* FluentBuilderGenerator.kt:500 */
  132    148   
    pub fn starting_block_index(mut self, input: i32) -> Self {
  133    149   
        self.inner = self.inner.starting_block_index(input);
  134    150   
        self
  135    151   
    }
  136         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         152  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         153  +
    /* FluentBuilderGenerator.kt:500 */
  137    154   
    pub fn set_starting_block_index(mut self, input: ::std::option::Option<i32>) -> Self {
  138    155   
        self.inner = self.inner.set_starting_block_index(input);
  139    156   
        self
  140    157   
    }
  141         -
    /// <p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         158  +
    /// /* FluentBuilderGenerator.kt:518 */<p>The block index from which the list should start. The list in the response will start from this block index or the next valid block index in the snapshot.</p>
         159  +
    /* FluentBuilderGenerator.kt:520 */
  142    160   
    pub fn get_starting_block_index(&self) -> &::std::option::Option<i32> {
  143    161   
        self.inner.get_starting_block_index()
  144    162   
    }
  145         -
    /// <p>The token to request the next page of results.</p>
         163  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The token to request the next page of results.</p>
         164  +
    /* FluentBuilderGenerator.kt:500 */
  146    165   
    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
  147    166   
        self.inner = self.inner.next_token(input.into());
  148    167   
        self
  149    168   
    }
  150         -
    /// <p>The token to request the next page of results.</p>
         169  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The token to request the next page of results.</p>
         170  +
    /* FluentBuilderGenerator.kt:500 */
  151    171   
    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
  152    172   
        self.inner = self.inner.set_next_token(input);
  153    173   
        self
  154    174   
    }
  155         -
    /// <p>The token to request the next page of results.</p>
         175  +
    /// /* FluentBuilderGenerator.kt:518 */<p>The token to request the next page of results.</p>
         176  +
    /* FluentBuilderGenerator.kt:520 */
  156    177   
    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
  157    178   
        self.inner.get_next_token()
  158    179   
    }
  159         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         180  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         181  +
    /* FluentBuilderGenerator.kt:500 */
  160    182   
    pub fn snapshot_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
  161    183   
        self.inner = self.inner.snapshot_id(input.into());
  162    184   
        self
  163    185   
    }
  164         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         186  +
    /// /* FluentBuilderGenerator.kt:498 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         187  +
    /* FluentBuilderGenerator.kt:500 */
  165    188   
    pub fn set_snapshot_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
  166    189   
        self.inner = self.inner.set_snapshot_id(input);
  167    190   
        self
  168    191   
    }
  169         -
    /// <p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         192  +
    /// /* FluentBuilderGenerator.kt:518 */<p>The ID of the snapshot from which to get block indexes and block tokens.</p>
         193  +
    /* FluentBuilderGenerator.kt:520 */
  170    194   
    pub fn get_snapshot_id(&self) -> &::std::option::Option<::std::string::String> {
  171    195   
        self.inner.get_snapshot_id()
  172    196   
    }
         197  +
    /* FluentBuilderGenerator.kt:282 */
  173    198   
}

tmp-codegen-diff/codegen-client-test/ebs/rust-client-codegen/src/operation/list_snapshot_blocks/paginator.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* PaginatorGenerator.kt:121 */
    2      3   
/// Paginator for [`ListSnapshotBlocks`](crate::operation::list_snapshot_blocks::ListSnapshotBlocks)
    3      4   
pub struct ListSnapshotBlocksPaginator {
    4      5   
    handle: std::sync::Arc<crate::client::Handle>,
    5      6   
    builder: crate::operation::list_snapshot_blocks::builders::ListSnapshotBlocksInputBuilder,
    6      7   
    stop_on_duplicate_token: bool,
    7      8   
}
    8      9   
    9     10   
impl ListSnapshotBlocksPaginator {
   10     11   
    /// Create a new paginator-wrapper
   11     12   
    pub(crate) fn new(

tmp-codegen-diff/codegen-client-test/ebs/rust-client-codegen/src/operation/put_snapshot_block.rs

@@ -1,1 +40,49 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* OperationGenerator.kt:77 */
    2      3   
/// Orchestration and serialization glue logic for `PutSnapshotBlock`.
           4  +
/* RustType.kt:516 */
    3      5   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
           6  +
/* RustType.kt:516 */
    4      7   
#[non_exhaustive]
           8  +
/* OperationGenerator.kt:84 */
    5      9   
pub struct PutSnapshotBlock;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl PutSnapshotBlock {
    7         -
    /// Creates a new `PutSnapshotBlock`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `PutSnapshotBlock`
          13  +
    /* OperationGenerator.kt:87 */
    8     14   
    pub fn new() -> Self {
          15  +
        /* OperationGenerator.kt:88 */
    9     16   
        Self
          17  +
        /* OperationGenerator.kt:87 */
   10     18   
    }
          19  +
    /* OperationGenerator.kt:138 */
   11     20   
    pub(crate) async fn orchestrate(
   12     21   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     22   
        input: crate::operation::put_snapshot_block::PutSnapshotBlockInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::put_snapshot_block::PutSnapshotBlockOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::put_snapshot_block::PutSnapshotBlockError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -57,66 +177,190 @@
   77     86   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   78     87   
            }
   79     88   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   80     89   
                config_override,
   81     90   
                client_config.config.clone(),
   82     91   
                &client_config.runtime_components,
   83     92   
            ));
   84     93   
        }
   85     94   
        runtime_plugins
   86     95   
    }
          96  +
    /* OperationGenerator.kt:85 */
   87     97   
}
          98  +
/* OperationRuntimePluginGenerator.kt:55 */
   88     99   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for PutSnapshotBlock {
   89    100   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   90    101   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("PutSnapshotBlock");
   91    102   
   92    103   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   93    104   
            PutSnapshotBlockRequestSerializer,
   94    105   
        ));
   95    106   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
   96    107   
            PutSnapshotBlockResponseDeserializer,
   97    108   
        ));
   98    109   
   99    110   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  100    111   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  101    112   
        ));
  102    113   
  103    114   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new("PutSnapshotBlock", "EBS"));
  104    115   
  105    116   
        ::std::option::Option::Some(cfg.freeze())
  106    117   
    }
  107    118   
  108    119   
    fn runtime_components(
  109    120   
        &self,
  110    121   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  111    122   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  112    123   
        #[allow(unused_mut)]
  113    124   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("PutSnapshotBlock")
  114    125   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  115    126   
            .with_interceptor(PutSnapshotBlockEndpointParamsInterceptor)
  116    127   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  117    128   
                crate::operation::put_snapshot_block::PutSnapshotBlockError,
  118    129   
            >::new())
  119    130   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  120    131   
                crate::operation::put_snapshot_block::PutSnapshotBlockError,
  121    132   
            >::new());
  122    133   
  123    134   
        ::std::borrow::Cow::Owned(rcb)
  124    135   
    }
  125    136   
}
  126    137   
         138  +
/* ResponseDeserializerGenerator.kt:64 */
  127    139   
#[derive(Debug)]
  128    140   
struct PutSnapshotBlockResponseDeserializer;
  129    141   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for PutSnapshotBlockResponseDeserializer {
  130    142   
    fn deserialize_nonstreaming(
  131    143   
        &self,
  132    144   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  133    145   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  134    146   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  135    147   
        let headers = response.headers();
  136    148   
        let body = response.body().bytes().expect("body loaded");
  137    149   
        #[allow(unused_mut)]
  138    150   
        let mut force_error = false;
  139    151   
  140    152   
        let parse_result = if !success && status != 201 || force_error {
  141    153   
            crate::protocol_serde::shape_put_snapshot_block::de_put_snapshot_block_http_error(status, headers, body)
  142    154   
        } else {
  143    155   
            crate::protocol_serde::shape_put_snapshot_block::de_put_snapshot_block_http_response(status, headers, body)
  144    156   
        };
  145    157   
        crate::protocol_serde::type_erase_result(parse_result)
  146    158   
    }
  147    159   
}
         160  +
/* RequestSerializerGenerator.kt:67 */
  148    161   
#[derive(Debug)]
  149    162   
struct PutSnapshotBlockRequestSerializer;
  150    163   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for PutSnapshotBlockRequestSerializer {
  151    164   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  152    165   
    fn serialize_input(
  153    166   
        &self,
  154    167   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  155    168   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  156    169   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  157    170   
        let input = input
@@ -194,207 +416,630 @@
  214    227   
            builder
  215    228   
        };
  216    229   
        let body = crate::protocol_serde::shape_put_snapshot_block_input::ser_block_data_http_payload(input.block_data)?.into_inner();
  217    230   
        if let Some(content_length) = body.content_length() {
  218    231   
            let content_length = content_length.to_string();
  219    232   
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http::header::CONTENT_LENGTH, &content_length);
  220    233   
        }
  221    234   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  222    235   
    }
  223    236   
}
         237  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  224    238   
#[derive(Debug)]
  225    239   
struct PutSnapshotBlockEndpointParamsInterceptor;
  226    240   
  227    241   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for PutSnapshotBlockEndpointParamsInterceptor {
  228    242   
    fn name(&self) -> &'static str {
  229    243   
        "PutSnapshotBlockEndpointParamsInterceptor"
  230    244   
    }
  231    245   
  232    246   
    fn read_before_execution(
  233    247   
        &self,
  234    248   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  235    249   
            '_,
  236    250   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  237    251   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  238    252   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  239    253   
        >,
  240    254   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  241    255   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  242    256   
        let _input = context
  243    257   
            .input()
  244    258   
            .downcast_ref::<PutSnapshotBlockInput>()
  245    259   
            .ok_or("failed to downcast to PutSnapshotBlockInput")?;
  246    260   
  247    261   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  248    262   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  249    263   
        })?;
  250    264   
        cfg.interceptor_state()
  251    265   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  252    266   
        ::std::result::Result::Ok(())
  253    267   
    }
  254    268   
}
  255    269   
  256    270   
// The get_* functions below are generated from JMESPath expressions in the
  257    271   
// operationContextParams trait. They target the operation's input shape.
  258    272   
         273  +
/* OperationErrorGenerator.kt:79 */
  259    274   
/// Error type for the `PutSnapshotBlockError` operation.
         275  +
/* RustType.kt:516 */
  260    276   
#[non_exhaustive]
         277  +
/* RustType.kt:516 */
  261    278   
#[derive(::std::fmt::Debug)]
  262         -
pub enum PutSnapshotBlockError {
  263         -
    /// <p>You do not have sufficient access to perform this action.</p>
         279  +
pub /* OperationErrorGenerator.kt:81 */ enum PutSnapshotBlockError {
         280  +
    /// /* OperationErrorGenerator.kt:83 */<p>You do not have sufficient access to perform this action.</p>
         281  +
    /* OperationErrorGenerator.kt:86 */
  264    282   
    AccessDeniedError(crate::types::error::AccessDeniedError),
  265         -
    /// <p>An internal error has occurred.</p>
         283  +
    /// /* OperationErrorGenerator.kt:83 */<p>An internal error has occurred.</p>
         284  +
    /* OperationErrorGenerator.kt:86 */
  266    285   
    InternalServerError(crate::types::error::InternalServerError),
  267         -
    /// <p>The number of API requests has exceed the maximum allowed API request throttling limit.</p>
         286  +
    /// /* OperationErrorGenerator.kt:83 */<p>The number of API requests has exceed the maximum allowed API request throttling limit.</p>
         287  +
    /* OperationErrorGenerator.kt:86 */
  268    288   
    RequestThrottledError(crate::types::error::RequestThrottledError),
  269         -
    /// <p>The specified resource does not exist.</p>
         289  +
    /// /* OperationErrorGenerator.kt:83 */<p>The specified resource does not exist.</p>
         290  +
    /* OperationErrorGenerator.kt:86 */
  270    291   
    ResourceNotFoundError(crate::types::error::ResourceNotFoundError),
  271         -
    /// <p>Your current service quotas do not allow you to perform this action.</p>
         292  +
    /// /* OperationErrorGenerator.kt:83 */<p>Your current service quotas do not allow you to perform this action.</p>
         293  +
    /* OperationErrorGenerator.kt:86 */
  272    294   
    ServiceQuotaExceededError(crate::types::error::ServiceQuotaExceededError),
  273         -
    /// <p>The input fails to satisfy the constraints of the EBS direct APIs.</p>
         295  +
    /// /* OperationErrorGenerator.kt:83 */<p>The input fails to satisfy the constraints of the EBS direct APIs.</p>
         296  +
    /* OperationErrorGenerator.kt:86 */
  274    297   
    ValidationError(crate::types::error::ValidationError),
         298  +
    /* OperationErrorGenerator.kt:88 */
  275    299   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  276    300   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  277    301   
    variable wildcard pattern and check `.code()`:
  278    302   
     \
  279    303   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  280    304   
     \
  281    305   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-PutSnapshotBlockError) for what information is available for the error.")]
  282    306   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         307  +
    /* OperationErrorGenerator.kt:81 */
  283    308   
}
         309  +
/* OperationErrorGenerator.kt:218 */
  284    310   
impl PutSnapshotBlockError {
         311  +
    /* OperationErrorGenerator.kt:219 */
  285    312   
    /// Creates the `PutSnapshotBlockError::Unhandled` variant from any error type.
  286    313   
    pub fn unhandled(
  287    314   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  288    315   
    ) -> Self {
  289    316   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  290    317   
            source: err.into(),
  291    318   
            meta: ::std::default::Default::default(),
  292    319   
        })
  293    320   
    }
  294    321   
  295    322   
    /// Creates the `PutSnapshotBlockError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  296    323   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  297    324   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  298    325   
            source: err.clone().into(),
  299    326   
            meta: err,
  300    327   
        })
  301    328   
    }
  302         -
    ///
         329  +
    /// /* OperationErrorGenerator.kt:236 */
  303    330   
    /// Returns error metadata, which includes the error code, message,
  304    331   
    /// request ID, and potentially additional information.
  305    332   
    ///
         333  +
    /* OperationErrorGenerator.kt:242 */
  306    334   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         335  +
        /* OperationErrorGenerator.kt:243 */
  307    336   
        match self {
         337  +
            /* OperationErrorGenerator.kt:246 */
  308    338   
            Self::AccessDeniedError(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
         339  +
            /* OperationErrorGenerator.kt:246 */
  309    340   
            Self::InternalServerError(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
         341  +
            /* OperationErrorGenerator.kt:246 */
  310    342   
            Self::RequestThrottledError(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
         343  +
            /* OperationErrorGenerator.kt:246 */
  311    344   
            Self::ResourceNotFoundError(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
         345  +
            /* OperationErrorGenerator.kt:246 */
  312    346   
            Self::ServiceQuotaExceededError(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
  313         -
            Self::ValidationError(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
  314         -
            Self::Unhandled(e) => &e.meta,
         347  +
            /* OperationErrorGenerator.kt:246 */ Self::ValidationError(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
         348  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         349  +
            /* OperationErrorGenerator.kt:243 */
  315    350   
        }
         351  +
        /* OperationErrorGenerator.kt:242 */
  316    352   
    }
         353  +
    /* OperationErrorGenerator.kt:257 */
  317    354   
    /// Returns `true` if the error kind is `PutSnapshotBlockError::AccessDeniedError`.
         355  +
    /* OperationErrorGenerator.kt:258 */
  318    356   
    pub fn is_access_denied_error(&self) -> bool {
         357  +
        /* OperationErrorGenerator.kt:259 */
  319    358   
        matches!(self, Self::AccessDeniedError(_))
         359  +
        /* OperationErrorGenerator.kt:258 */
  320    360   
    }
         361  +
    /* OperationErrorGenerator.kt:257 */
  321    362   
    /// Returns `true` if the error kind is `PutSnapshotBlockError::InternalServerError`.
         363  +
    /* OperationErrorGenerator.kt:258 */
  322    364   
    pub fn is_internal_server_error(&self) -> bool {
         365  +
        /* OperationErrorGenerator.kt:259 */
  323    366   
        matches!(self, Self::InternalServerError(_))
         367  +
        /* OperationErrorGenerator.kt:258 */
  324    368   
    }
         369  +
    /* OperationErrorGenerator.kt:257 */
  325    370   
    /// Returns `true` if the error kind is `PutSnapshotBlockError::RequestThrottledError`.
         371  +
    /* OperationErrorGenerator.kt:258 */
  326    372   
    pub fn is_request_throttled_error(&self) -> bool {
         373  +
        /* OperationErrorGenerator.kt:259 */
  327    374   
        matches!(self, Self::RequestThrottledError(_))
         375  +
        /* OperationErrorGenerator.kt:258 */
  328    376   
    }
         377  +
    /* OperationErrorGenerator.kt:257 */
  329    378   
    /// Returns `true` if the error kind is `PutSnapshotBlockError::ResourceNotFoundError`.
         379  +
    /* OperationErrorGenerator.kt:258 */
  330    380   
    pub fn is_resource_not_found_error(&self) -> bool {
         381  +
        /* OperationErrorGenerator.kt:259 */
  331    382   
        matches!(self, Self::ResourceNotFoundError(_))
         383  +
        /* OperationErrorGenerator.kt:258 */
  332    384   
    }
         385  +
    /* OperationErrorGenerator.kt:257 */
  333    386   
    /// Returns `true` if the error kind is `PutSnapshotBlockError::ServiceQuotaExceededError`.
         387  +
    /* OperationErrorGenerator.kt:258 */
  334    388   
    pub fn is_service_quota_exceeded_error(&self) -> bool {
         389  +
        /* OperationErrorGenerator.kt:259 */
  335    390   
        matches!(self, Self::ServiceQuotaExceededError(_))
         391  +
        /* OperationErrorGenerator.kt:258 */
  336    392   
    }
         393  +
    /* OperationErrorGenerator.kt:257 */
  337    394   
    /// Returns `true` if the error kind is `PutSnapshotBlockError::ValidationError`.
         395  +
    /* OperationErrorGenerator.kt:258 */
  338    396   
    pub fn is_validation_error(&self) -> bool {
         397  +
        /* OperationErrorGenerator.kt:259 */
  339    398   
        matches!(self, Self::ValidationError(_))
         399  +
        /* OperationErrorGenerator.kt:258 */
  340    400   
    }
         401  +
    /* OperationErrorGenerator.kt:218 */
  341    402   
}
         403  +
/* OperationErrorGenerator.kt:269 */
  342    404   
impl ::std::error::Error for PutSnapshotBlockError {
         405  +
    /* OperationErrorGenerator.kt:270 */
  343    406   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         407  +
        /* OperationErrorGenerator.kt:318 */
  344    408   
        match self {
  345         -
            Self::AccessDeniedError(_inner) => ::std::option::Option::Some(_inner),
  346         -
            Self::InternalServerError(_inner) => ::std::option::Option::Some(_inner),
  347         -
            Self::RequestThrottledError(_inner) => ::std::option::Option::Some(_inner),
  348         -
            Self::ResourceNotFoundError(_inner) => ::std::option::Option::Some(_inner),
  349         -
            Self::ServiceQuotaExceededError(_inner) => ::std::option::Option::Some(_inner),
  350         -
            Self::ValidationError(_inner) => ::std::option::Option::Some(_inner),
  351         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         409  +
            /* OperationErrorGenerator.kt:321 */
         410  +
            Self::AccessDeniedError(_inner) =>
         411  +
            /* OperationErrorGenerator.kt:283 */
         412  +
            {
         413  +
                ::std::option::Option::Some(_inner)
         414  +
            }
         415  +
            ,
         416  +
            /* OperationErrorGenerator.kt:321 */
         417  +
            Self::InternalServerError(_inner) =>
         418  +
            /* OperationErrorGenerator.kt:283 */
         419  +
            {
         420  +
                ::std::option::Option::Some(_inner)
         421  +
            }
         422  +
            ,
         423  +
            /* OperationErrorGenerator.kt:321 */
         424  +
            Self::RequestThrottledError(_inner) =>
         425  +
            /* OperationErrorGenerator.kt:283 */
         426  +
            {
         427  +
                ::std::option::Option::Some(_inner)
         428  +
            }
         429  +
            ,
         430  +
            /* OperationErrorGenerator.kt:321 */
         431  +
            Self::ResourceNotFoundError(_inner) =>
         432  +
            /* OperationErrorGenerator.kt:283 */
         433  +
            {
         434  +
                ::std::option::Option::Some(_inner)
         435  +
            }
         436  +
            ,
         437  +
            /* OperationErrorGenerator.kt:321 */
         438  +
            Self::ServiceQuotaExceededError(_inner) =>
         439  +
            /* OperationErrorGenerator.kt:283 */
         440  +
            {
         441  +
                ::std::option::Option::Some(_inner)
         442  +
            }
         443  +
            ,
         444  +
            /* OperationErrorGenerator.kt:321 */
         445  +
            Self::ValidationError(_inner) =>
         446  +
            /* OperationErrorGenerator.kt:283 */
         447  +
            {
         448  +
                ::std::option::Option::Some(_inner)
         449  +
            }
         450  +
            ,
         451  +
            /* OperationErrorGenerator.kt:326 */
         452  +
            Self::Unhandled(_inner) => {
         453  +
                /* OperationErrorGenerator.kt:279 */
         454  +
                ::std::option::Option::Some(&*_inner.source)
         455  +
                /* OperationErrorGenerator.kt:326 */
         456  +
            } /* OperationErrorGenerator.kt:318 */
  352    457   
        }
         458  +
        /* OperationErrorGenerator.kt:270 */
  353    459   
    }
         460  +
    /* OperationErrorGenerator.kt:269 */
  354    461   
}
         462  +
/* OperationErrorGenerator.kt:133 */
  355    463   
impl ::std::fmt::Display for PutSnapshotBlockError {
         464  +
    /* OperationErrorGenerator.kt:134 */
  356    465   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         466  +
        /* OperationErrorGenerator.kt:318 */
  357    467   
        match self {
  358         -
            Self::AccessDeniedError(_inner) => _inner.fmt(f),
  359         -
            Self::InternalServerError(_inner) => _inner.fmt(f),
  360         -
            Self::RequestThrottledError(_inner) => _inner.fmt(f),
  361         -
            Self::ResourceNotFoundError(_inner) => _inner.fmt(f),
  362         -
            Self::ServiceQuotaExceededError(_inner) => _inner.fmt(f),
  363         -
            Self::ValidationError(_inner) => _inner.fmt(f),
         468  +
            /* OperationErrorGenerator.kt:321 */
         469  +
            Self::AccessDeniedError(_inner) =>
         470  +
            /* OperationErrorGenerator.kt:151 */
         471  +
            {
         472  +
                _inner.fmt(f)
         473  +
            }
         474  +
            ,
         475  +
            /* OperationErrorGenerator.kt:321 */
         476  +
            Self::InternalServerError(_inner) =>
         477  +
            /* OperationErrorGenerator.kt:151 */
         478  +
            {
         479  +
                _inner.fmt(f)
         480  +
            }
         481  +
            ,
         482  +
            /* OperationErrorGenerator.kt:321 */
         483  +
            Self::RequestThrottledError(_inner) =>
         484  +
            /* OperationErrorGenerator.kt:151 */
         485  +
            {
         486  +
                _inner.fmt(f)
         487  +
            }
         488  +
            ,
         489  +
            /* OperationErrorGenerator.kt:321 */
         490  +
            Self::ResourceNotFoundError(_inner) =>
         491  +
            /* OperationErrorGenerator.kt:151 */
         492  +
            {
         493  +
                _inner.fmt(f)
         494  +
            }
         495  +
            ,
         496  +
            /* OperationErrorGenerator.kt:321 */
         497  +
            Self::ServiceQuotaExceededError(_inner) =>
         498  +
            /* OperationErrorGenerator.kt:151 */
         499  +
            {
         500  +
                _inner.fmt(f)
         501  +
            }
         502  +
            ,
         503  +
            /* OperationErrorGenerator.kt:321 */
         504  +
            Self::ValidationError(_inner) =>
         505  +
            /* OperationErrorGenerator.kt:151 */
         506  +
            {
         507  +
                _inner.fmt(f)
         508  +
            }
         509  +
            ,
         510  +
            /* OperationErrorGenerator.kt:326 */
  364    511   
            Self::Unhandled(_inner) => {
         512  +
                /* OperationErrorGenerator.kt:139 */
  365    513   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  366    514   
                    write!(f, "unhandled error ({code})")
  367    515   
                } else {
  368    516   
                    f.write_str("unhandled error")
  369    517   
                }
  370         -
            }
         518  +
                /* OperationErrorGenerator.kt:326 */
         519  +
            } /* OperationErrorGenerator.kt:318 */
  371    520   
        }
         521  +
        /* OperationErrorGenerator.kt:134 */
  372    522   
    }
         523  +
    /* OperationErrorGenerator.kt:133 */
  373    524   
}
         525  +
/* OperationErrorGenerator.kt:182 */
  374    526   
impl ::aws_smithy_types::retry::ProvideErrorKind for PutSnapshotBlockError {
         527  +
    /* OperationErrorGenerator.kt:186 */
  375    528   
    fn code(&self) -> ::std::option::Option<&str> {
         529  +
        /* OperationErrorGenerator.kt:187 */
  376    530   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         531  +
        /* OperationErrorGenerator.kt:186 */
  377    532   
    }
         533  +
    /* OperationErrorGenerator.kt:190 */
  378    534   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         535  +
        /* OperationErrorGenerator.kt:197 */
  379    536   
        ::std::option::Option::None
         537  +
        /* OperationErrorGenerator.kt:190 */
  380    538   
    }
         539  +
    /* OperationErrorGenerator.kt:182 */
  381    540   
}
         541  +
/* OperationErrorGenerator.kt:163 */
  382    542   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for PutSnapshotBlockError {
         543  +
    /* OperationErrorGenerator.kt:164 */
  383    544   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         545  +
        /* OperationErrorGenerator.kt:318 */
  384    546   
        match self {
  385         -
            Self::AccessDeniedError(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
  386         -
            Self::InternalServerError(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
  387         -
            Self::RequestThrottledError(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
  388         -
            Self::ResourceNotFoundError(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
  389         -
            Self::ServiceQuotaExceededError(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
  390         -
            Self::ValidationError(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
  391         -
            Self::Unhandled(_inner) => &_inner.meta,
         547  +
            /* OperationErrorGenerator.kt:321 */
         548  +
            Self::AccessDeniedError(_inner) =>
         549  +
            /* OperationErrorGenerator.kt:169 */
         550  +
            {
         551  +
                ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner)
         552  +
            }
         553  +
            ,
         554  +
            /* OperationErrorGenerator.kt:321 */
         555  +
            Self::InternalServerError(_inner) =>
         556  +
            /* OperationErrorGenerator.kt:169 */
         557  +
            {
         558  +
                ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner)
         559  +
            }
         560  +
            ,
         561  +
            /* OperationErrorGenerator.kt:321 */
         562  +
            Self::RequestThrottledError(_inner) =>
         563  +
            /* OperationErrorGenerator.kt:169 */
         564  +
            {
         565  +
                ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner)
         566  +
            }
         567  +
            ,
         568  +
            /* OperationErrorGenerator.kt:321 */
         569  +
            Self::ResourceNotFoundError(_inner) =>
         570  +
            /* OperationErrorGenerator.kt:169 */
         571  +
            {
         572  +
                ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner)
         573  +
            }
         574  +
            ,
         575  +
            /* OperationErrorGenerator.kt:321 */
         576  +
            Self::ServiceQuotaExceededError(_inner) =>
         577  +
            /* OperationErrorGenerator.kt:169 */
         578  +
            {
         579  +
                ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner)
         580  +
            }
         581  +
            ,
         582  +
            /* OperationErrorGenerator.kt:321 */
         583  +
            Self::ValidationError(_inner) =>
         584  +
            /* OperationErrorGenerator.kt:169 */
         585  +
            {
         586  +
                ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner)
         587  +
            }
         588  +
            ,
         589  +
            /* OperationErrorGenerator.kt:326 */
         590  +
            Self::Unhandled(_inner) => {
         591  +
                /* OperationErrorGenerator.kt:168 */
         592  +
                &_inner.meta
         593  +
                /* OperationErrorGenerator.kt:326 */
         594  +
            } /* OperationErrorGenerator.kt:318 */
  392    595   
        }
         596  +
        /* OperationErrorGenerator.kt:164 */
  393    597   
    }
         598  +
    /* OperationErrorGenerator.kt:163 */
  394    599   
}
         600  +
/* OperationErrorGenerator.kt:109 */
  395    601   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for PutSnapshotBlockError {
         602  +
    /* OperationErrorGenerator.kt:110 */
  396    603   
    fn create_unhandled_error(
  397    604   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  398    605   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  399    606   
    ) -> Self {
         607  +
        /* OperationErrorGenerator.kt:121 */
  400    608   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  401    609   
            source,
  402    610   
            meta: meta.unwrap_or_default(),
  403    611   
        })
         612  +
        /* OperationErrorGenerator.kt:110 */
  404    613   
    }
         614  +
    /* OperationErrorGenerator.kt:109 */
  405    615   
}
  406    616   
         617  +
/* CodegenDelegator.kt:255 */
  407    618   
pub use crate::operation::put_snapshot_block::_put_snapshot_block_output::PutSnapshotBlockOutput;
  408    619   
         620  +
/* CodegenDelegator.kt:255 */
  409    621   
pub use crate::operation::put_snapshot_block::_put_snapshot_block_input::PutSnapshotBlockInput;
  410    622   
         623  +
/* RustModule.kt:172 */
  411    624   
mod _put_snapshot_block_input;
  412    625   
         626  +
/* RustModule.kt:172 */
  413    627   
mod _put_snapshot_block_output;
  414    628   
  415         -
/// Builders
         629  +
/// /* CodegenDelegator.kt:51 */Builders
  416    630   
pub mod builders;

tmp-codegen-diff/codegen-client-test/ebs/rust-client-codegen/src/operation/put_snapshot_block/_put_snapshot_block_input.rs

@@ -1,1 +224,374 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
    4         -
pub struct PutSnapshotBlockInput {
    5         -
    /// <p>The ID of the snapshot.</p>
           6  +
pub /* StructureGenerator.kt:201 */ struct PutSnapshotBlockInput {
           7  +
    /// /* StructureGenerator.kt:231 */<p>The ID of the snapshot.</p>
    6      8   
    pub snapshot_id: ::std::option::Option<::std::string::String>,
    7         -
    /// <p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
           9  +
    /// /* StructureGenerator.kt:231 */<p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
    8     10   
    pub block_index: ::std::option::Option<i32>,
    9         -
    /// <p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
          11  +
    /// /* StructureGenerator.kt:231 */<p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
   10     12   
    pub checksum: ::std::option::Option<::std::string::String>,
   11         -
    /// <p>The progress of the write process, as a percentage.</p>
          13  +
    /// /* StructureGenerator.kt:231 */<p>The progress of the write process, as a percentage.</p>
   12     14   
    pub progress: ::std::option::Option<i32>,
   13         -
    /// <p>The data to write to the block.</p>
          15  +
    /// /* StructureGenerator.kt:231 */<p>The data to write to the block.</p>
   14     16   
    /// <p>The block data is not signed as part of the Signature Version 4 signing process. As a result, you must generate and provide a Base64-encoded SHA256 checksum for the block data using the <b>x-amz-Checksum</b> header. Also, you must specify the checksum algorithm using the <b>x-amz-Checksum-Algorithm</b> header. The checksum that you provide is part of the Signature Version 4 signing process. It is validated against a checksum generated by Amazon EBS to ensure the validity and authenticity of the data. If the checksums do not correspond, the request fails. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-checksums"> Using checksums with the EBS direct APIs</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
   15     17   
    pub block_data: ::aws_smithy_types::byte_stream::ByteStream,
   16         -
    /// <p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
          18  +
    /// /* StructureGenerator.kt:231 */<p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
   17     19   
    /// <p>Valid values: <code>524288</code></p>
   18     20   
    pub data_length: ::std::option::Option<i32>,
   19         -
    /// <p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
          21  +
    /// /* StructureGenerator.kt:231 */<p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
   20     22   
    pub checksum_algorithm: ::std::option::Option<crate::types::ChecksumAlgorithm>,
          23  +
    /* StructureGenerator.kt:201 */
   21     24   
}
          25  +
/* StructureGenerator.kt:135 */
   22     26   
impl PutSnapshotBlockInput {
   23         -
    /// <p>The ID of the snapshot.</p>
          27  +
    /// /* StructureGenerator.kt:231 */<p>The ID of the snapshot.</p>
          28  +
    /* StructureGenerator.kt:166 */
   24     29   
    pub fn snapshot_id(&self) -> ::std::option::Option<&str> {
          30  +
        /* StructureGenerator.kt:169 */
   25     31   
        self.snapshot_id.as_deref()
          32  +
        /* StructureGenerator.kt:166 */
   26     33   
    }
   27         -
    /// <p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
          34  +
    /// /* StructureGenerator.kt:231 */<p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
          35  +
    /* StructureGenerator.kt:166 */
   28     36   
    pub fn block_index(&self) -> ::std::option::Option<i32> {
          37  +
        /* StructureGenerator.kt:168 */
   29     38   
        self.block_index
          39  +
        /* StructureGenerator.kt:166 */
   30     40   
    }
   31         -
    /// <p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
          41  +
    /// /* StructureGenerator.kt:231 */<p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
          42  +
    /* StructureGenerator.kt:166 */
   32     43   
    pub fn checksum(&self) -> ::std::option::Option<&str> {
          44  +
        /* StructureGenerator.kt:169 */
   33     45   
        self.checksum.as_deref()
          46  +
        /* StructureGenerator.kt:166 */
   34     47   
    }
   35         -
    /// <p>The progress of the write process, as a percentage.</p>
          48  +
    /// /* StructureGenerator.kt:231 */<p>The progress of the write process, as a percentage.</p>
          49  +
    /* StructureGenerator.kt:166 */
   36     50   
    pub fn progress(&self) -> ::std::option::Option<i32> {
          51  +
        /* StructureGenerator.kt:168 */
   37     52   
        self.progress
          53  +
        /* StructureGenerator.kt:166 */
   38     54   
    }
   39         -
    /// <p>The data to write to the block.</p>
          55  +
    /// /* StructureGenerator.kt:231 */<p>The data to write to the block.</p>
   40     56   
    /// <p>The block data is not signed as part of the Signature Version 4 signing process. As a result, you must generate and provide a Base64-encoded SHA256 checksum for the block data using the <b>x-amz-Checksum</b> header. Also, you must specify the checksum algorithm using the <b>x-amz-Checksum-Algorithm</b> header. The checksum that you provide is part of the Signature Version 4 signing process. It is validated against a checksum generated by Amazon EBS to ensure the validity and authenticity of the data. If the checksums do not correspond, the request fails. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-checksums"> Using checksums with the EBS direct APIs</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
          57  +
    /* StructureGenerator.kt:166 */
   41     58   
    pub fn block_data(&self) -> &::aws_smithy_types::byte_stream::ByteStream {
          59  +
        /* StructureGenerator.kt:172 */
   42     60   
        &self.block_data
          61  +
        /* StructureGenerator.kt:166 */
   43     62   
    }
   44         -
    /// <p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
          63  +
    /// /* StructureGenerator.kt:231 */<p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
   45     64   
    /// <p>Valid values: <code>524288</code></p>
          65  +
    /* StructureGenerator.kt:166 */
   46     66   
    pub fn data_length(&self) -> ::std::option::Option<i32> {
          67  +
        /* StructureGenerator.kt:168 */
   47     68   
        self.data_length
          69  +
        /* StructureGenerator.kt:166 */
   48     70   
    }
   49         -
    /// <p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
          71  +
    /// /* StructureGenerator.kt:231 */<p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
          72  +
    /* StructureGenerator.kt:166 */
   50     73   
    pub fn checksum_algorithm(&self) -> ::std::option::Option<&crate::types::ChecksumAlgorithm> {
          74  +
        /* StructureGenerator.kt:170 */
   51     75   
        self.checksum_algorithm.as_ref()
          76  +
        /* StructureGenerator.kt:166 */
   52     77   
    }
          78  +
    /* StructureGenerator.kt:135 */
   53     79   
}
          80  +
/* StructureGenerator.kt:101 */
   54     81   
impl ::std::fmt::Debug for PutSnapshotBlockInput {
          82  +
    /* StructureGenerator.kt:105 */
   55     83   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
          84  +
        /* StructureGenerator.kt:106 */
   56     85   
        let mut formatter = f.debug_struct("PutSnapshotBlockInput");
          86  +
        /* StructureGenerator.kt:121 */
   57     87   
        formatter.field("snapshot_id", &self.snapshot_id);
          88  +
        /* StructureGenerator.kt:121 */
   58     89   
        formatter.field("block_index", &self.block_index);
          90  +
        /* StructureGenerator.kt:121 */
   59     91   
        formatter.field("checksum", &self.checksum);
          92  +
        /* StructureGenerator.kt:121 */
   60     93   
        formatter.field("progress", &self.progress);
          94  +
        /* StructureGenerator.kt:121 */
   61     95   
        formatter.field("block_data", &"*** Sensitive Data Redacted ***");
          96  +
        /* StructureGenerator.kt:121 */
   62     97   
        formatter.field("data_length", &self.data_length);
          98  +
        /* StructureGenerator.kt:121 */
   63     99   
        formatter.field("checksum_algorithm", &self.checksum_algorithm);
         100  +
        /* StructureGenerator.kt:126 */
   64    101   
        formatter.finish()
         102  +
        /* StructureGenerator.kt:105 */
   65    103   
    }
         104  +
    /* StructureGenerator.kt:101 */
   66    105   
}
         106  +
/* ClientCodegenVisitor.kt:237 */
   67    107   
impl PutSnapshotBlockInput {
   68         -
    /// Creates a new builder-style object to manufacture [`PutSnapshotBlockInput`](crate::operation::put_snapshot_block::PutSnapshotBlockInput).
         108  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`PutSnapshotBlockInput`](crate::operation::put_snapshot_block::PutSnapshotBlockInput).
         109  +
    /* BuilderGenerator.kt:175 */
   69    110   
    pub fn builder() -> crate::operation::put_snapshot_block::builders::PutSnapshotBlockInputBuilder {
         111  +
        /* BuilderGenerator.kt:176 */
   70    112   
        crate::operation::put_snapshot_block::builders::PutSnapshotBlockInputBuilder::default()
         113  +
        /* BuilderGenerator.kt:175 */
   71    114   
    }
         115  +
    /* ClientCodegenVisitor.kt:237 */
   72    116   
}
   73    117   
   74         -
/// A builder for [`PutSnapshotBlockInput`](crate::operation::put_snapshot_block::PutSnapshotBlockInput).
         118  +
/// /* BuilderGenerator.kt:342 */A builder for [`PutSnapshotBlockInput`](crate::operation::put_snapshot_block::PutSnapshotBlockInput).
         119  +
/* RustType.kt:516 */
   75    120   
#[derive(::std::default::Default)]
         121  +
/* RustType.kt:516 */
   76    122   
#[non_exhaustive]
         123  +
/* BuilderGenerator.kt:345 */
   77    124   
pub struct PutSnapshotBlockInputBuilder {
   78         -
    pub(crate) snapshot_id: ::std::option::Option<::std::string::String>,
   79         -
    pub(crate) block_index: ::std::option::Option<i32>,
   80         -
    pub(crate) checksum: ::std::option::Option<::std::string::String>,
   81         -
    pub(crate) progress: ::std::option::Option<i32>,
   82         -
    pub(crate) block_data: ::std::option::Option<::aws_smithy_types::byte_stream::ByteStream>,
   83         -
    pub(crate) data_length: ::std::option::Option<i32>,
         125  +
    /* BuilderGenerator.kt:275 */ pub(crate) snapshot_id: ::std::option::Option<::std::string::String>,
         126  +
    /* BuilderGenerator.kt:275 */ pub(crate) block_index: ::std::option::Option<i32>,
         127  +
    /* BuilderGenerator.kt:275 */ pub(crate) checksum: ::std::option::Option<::std::string::String>,
         128  +
    /* BuilderGenerator.kt:275 */ pub(crate) progress: ::std::option::Option<i32>,
         129  +
    /* BuilderGenerator.kt:275 */ pub(crate) block_data: ::std::option::Option<::aws_smithy_types::byte_stream::ByteStream>,
         130  +
    /* BuilderGenerator.kt:275 */ pub(crate) data_length: ::std::option::Option<i32>,
         131  +
    /* BuilderGenerator.kt:275 */
   84    132   
    pub(crate) checksum_algorithm: ::std::option::Option<crate::types::ChecksumAlgorithm>,
         133  +
    /* BuilderGenerator.kt:345 */
   85    134   
}
         135  +
/* BuilderGenerator.kt:355 */
   86    136   
impl PutSnapshotBlockInputBuilder {
   87         -
    /// <p>The ID of the snapshot.</p>
   88         -
    /// This field is required.
         137  +
    /// /* BuilderGenerator.kt:286 */<p>The ID of the snapshot.</p>
         138  +
    /// /* BuilderGenerator.kt:288 */This field is required.
         139  +
    /* BuilderGenerator.kt:291 */
   89    140   
    pub fn snapshot_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
         141  +
        /* BuilderGenerator.kt:292 */
   90    142   
        self.snapshot_id = ::std::option::Option::Some(input.into());
         143  +
        /* BuilderGenerator.kt:293 */
   91    144   
        self
         145  +
        /* BuilderGenerator.kt:291 */
   92    146   
    }
   93         -
    /// <p>The ID of the snapshot.</p>
         147  +
    /// /* BuilderGenerator.kt:312 */<p>The ID of the snapshot.</p>
         148  +
    /* BuilderGenerator.kt:314 */
   94    149   
    pub fn set_snapshot_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
         150  +
        /* BuilderGenerator.kt:315 */
   95    151   
        self.snapshot_id = input;
   96    152   
        self
         153  +
        /* BuilderGenerator.kt:314 */
   97    154   
    }
   98         -
    /// <p>The ID of the snapshot.</p>
         155  +
    /// /* BuilderGenerator.kt:334 */<p>The ID of the snapshot.</p>
         156  +
    /* BuilderGenerator.kt:336 */
   99    157   
    pub fn get_snapshot_id(&self) -> &::std::option::Option<::std::string::String> {
         158  +
        /* BuilderGenerator.kt:337 */
  100    159   
        &self.snapshot_id
         160  +
        /* BuilderGenerator.kt:336 */
  101    161   
    }
  102         -
    /// <p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
  103         -
    /// This field is required.
         162  +
    /// /* BuilderGenerator.kt:286 */<p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
         163  +
    /// /* BuilderGenerator.kt:288 */This field is required.
         164  +
    /* BuilderGenerator.kt:291 */
  104    165   
    pub fn block_index(mut self, input: i32) -> Self {
         166  +
        /* BuilderGenerator.kt:292 */
  105    167   
        self.block_index = ::std::option::Option::Some(input);
         168  +
        /* BuilderGenerator.kt:293 */
  106    169   
        self
         170  +
        /* BuilderGenerator.kt:291 */
  107    171   
    }
  108         -
    /// <p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
         172  +
    /// /* BuilderGenerator.kt:312 */<p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
         173  +
    /* BuilderGenerator.kt:314 */
  109    174   
    pub fn set_block_index(mut self, input: ::std::option::Option<i32>) -> Self {
         175  +
        /* BuilderGenerator.kt:315 */
  110    176   
        self.block_index = input;
  111    177   
        self
         178  +
        /* BuilderGenerator.kt:314 */
  112    179   
    }
  113         -
    /// <p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
         180  +
    /// /* BuilderGenerator.kt:334 */<p>The block index of the block in which to write the data. A block index is a logical index in units of <code>512</code> KiB blocks. To identify the block index, divide the logical offset of the data in the logical volume by the block size (logical offset of data/<code>524288</code>). The logical offset of the data must be <code>512</code> KiB aligned.</p>
         181  +
    /* BuilderGenerator.kt:336 */
  114    182   
    pub fn get_block_index(&self) -> &::std::option::Option<i32> {
         183  +
        /* BuilderGenerator.kt:337 */
  115    184   
        &self.block_index
         185  +
        /* BuilderGenerator.kt:336 */
  116    186   
    }
  117         -
    /// <p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
  118         -
    /// This field is required.
         187  +
    /// /* BuilderGenerator.kt:286 */<p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
         188  +
    /// /* BuilderGenerator.kt:288 */This field is required.
         189  +
    /* BuilderGenerator.kt:291 */
  119    190   
    pub fn checksum(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
         191  +
        /* BuilderGenerator.kt:292 */
  120    192   
        self.checksum = ::std::option::Option::Some(input.into());
         193  +
        /* BuilderGenerator.kt:293 */
  121    194   
        self
         195  +
        /* BuilderGenerator.kt:291 */
  122    196   
    }
  123         -
    /// <p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
         197  +
    /// /* BuilderGenerator.kt:312 */<p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
         198  +
    /* BuilderGenerator.kt:314 */
  124    199   
    pub fn set_checksum(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
         200  +
        /* BuilderGenerator.kt:315 */
  125    201   
        self.checksum = input;
  126    202   
        self
         203  +
        /* BuilderGenerator.kt:314 */
  127    204   
    }
  128         -
    /// <p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
         205  +
    /// /* BuilderGenerator.kt:334 */<p>A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are supported.</p>
         206  +
    /* BuilderGenerator.kt:336 */
  129    207   
    pub fn get_checksum(&self) -> &::std::option::Option<::std::string::String> {
         208  +
        /* BuilderGenerator.kt:337 */
  130    209   
        &self.checksum
         210  +
        /* BuilderGenerator.kt:336 */
  131    211   
    }
  132         -
    /// <p>The progress of the write process, as a percentage.</p>
         212  +
    /// /* BuilderGenerator.kt:286 */<p>The progress of the write process, as a percentage.</p>
         213  +
    /* BuilderGenerator.kt:291 */
  133    214   
    pub fn progress(mut self, input: i32) -> Self {
         215  +
        /* BuilderGenerator.kt:292 */
  134    216   
        self.progress = ::std::option::Option::Some(input);
         217  +
        /* BuilderGenerator.kt:293 */
  135    218   
        self
         219  +
        /* BuilderGenerator.kt:291 */
  136    220   
    }
  137         -
    /// <p>The progress of the write process, as a percentage.</p>
         221  +
    /// /* BuilderGenerator.kt:312 */<p>The progress of the write process, as a percentage.</p>
         222  +
    /* BuilderGenerator.kt:314 */
  138    223   
    pub fn set_progress(mut self, input: ::std::option::Option<i32>) -> Self {
         224  +
        /* BuilderGenerator.kt:315 */
  139    225   
        self.progress = input;
  140    226   
        self
         227  +
        /* BuilderGenerator.kt:314 */
  141    228   
    }
  142         -
    /// <p>The progress of the write process, as a percentage.</p>
         229  +
    /// /* BuilderGenerator.kt:334 */<p>The progress of the write process, as a percentage.</p>
         230  +
    /* BuilderGenerator.kt:336 */
  143    231   
    pub fn get_progress(&self) -> &::std::option::Option<i32> {
         232  +
        /* BuilderGenerator.kt:337 */
  144    233   
        &self.progress
         234  +
        /* BuilderGenerator.kt:336 */
  145    235   
    }
  146         -
    /// <p>The data to write to the block.</p>
         236  +
    /// /* BuilderGenerator.kt:286 */<p>The data to write to the block.</p>
  147    237   
    /// <p>The block data is not signed as part of the Signature Version 4 signing process. As a result, you must generate and provide a Base64-encoded SHA256 checksum for the block data using the <b>x-amz-Checksum</b> header. Also, you must specify the checksum algorithm using the <b>x-amz-Checksum-Algorithm</b> header. The checksum that you provide is part of the Signature Version 4 signing process. It is validated against a checksum generated by Amazon EBS to ensure the validity and authenticity of the data. If the checksums do not correspond, the request fails. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-checksums"> Using checksums with the EBS direct APIs</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
  148         -
    /// This field is required.
         238  +
    /// /* BuilderGenerator.kt:288 */This field is required.
         239  +
    /* BuilderGenerator.kt:291 */
  149    240   
    pub fn block_data(mut self, input: ::aws_smithy_types::byte_stream::ByteStream) -> Self {
         241  +
        /* BuilderGenerator.kt:292 */
  150    242   
        self.block_data = ::std::option::Option::Some(input);
         243  +
        /* BuilderGenerator.kt:293 */
  151    244   
        self
         245  +
        /* BuilderGenerator.kt:291 */
  152    246   
    }
  153         -
    /// <p>The data to write to the block.</p>
         247  +
    /// /* BuilderGenerator.kt:312 */<p>The data to write to the block.</p>
  154    248   
    /// <p>The block data is not signed as part of the Signature Version 4 signing process. As a result, you must generate and provide a Base64-encoded SHA256 checksum for the block data using the <b>x-amz-Checksum</b> header. Also, you must specify the checksum algorithm using the <b>x-amz-Checksum-Algorithm</b> header. The checksum that you provide is part of the Signature Version 4 signing process. It is validated against a checksum generated by Amazon EBS to ensure the validity and authenticity of the data. If the checksums do not correspond, the request fails. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-checksums"> Using checksums with the EBS direct APIs</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
         249  +
    /* BuilderGenerator.kt:314 */
  155    250   
    pub fn set_block_data(mut self, input: ::std::option::Option<::aws_smithy_types::byte_stream::ByteStream>) -> Self {
         251  +
        /* BuilderGenerator.kt:315 */
  156    252   
        self.block_data = input;
  157    253   
        self
         254  +
        /* BuilderGenerator.kt:314 */
  158    255   
    }
  159         -
    /// <p>The data to write to the block.</p>
         256  +
    /// /* BuilderGenerator.kt:334 */<p>The data to write to the block.</p>
  160    257   
    /// <p>The block data is not signed as part of the Signature Version 4 signing process. As a result, you must generate and provide a Base64-encoded SHA256 checksum for the block data using the <b>x-amz-Checksum</b> header. Also, you must specify the checksum algorithm using the <b>x-amz-Checksum-Algorithm</b> header. The checksum that you provide is part of the Signature Version 4 signing process. It is validated against a checksum generated by Amazon EBS to ensure the validity and authenticity of the data. If the checksums do not correspond, the request fails. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-checksums"> Using checksums with the EBS direct APIs</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>.</p>
         258  +
    /* BuilderGenerator.kt:336 */
  161    259   
    pub fn get_block_data(&self) -> &::std::option::Option<::aws_smithy_types::byte_stream::ByteStream> {
         260  +
        /* BuilderGenerator.kt:337 */
  162    261   
        &self.block_data
         262  +
        /* BuilderGenerator.kt:336 */
  163    263   
    }
  164         -
    /// <p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
         264  +
    /// /* BuilderGenerator.kt:286 */<p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
  165    265   
    /// <p>Valid values: <code>524288</code></p>
  166         -
    /// This field is required.
         266  +
    /// /* BuilderGenerator.kt:288 */This field is required.
         267  +
    /* BuilderGenerator.kt:291 */
  167    268   
    pub fn data_length(mut self, input: i32) -> Self {
         269  +
        /* BuilderGenerator.kt:292 */
  168    270   
        self.data_length = ::std::option::Option::Some(input);
         271  +
        /* BuilderGenerator.kt:293 */
  169    272   
        self
         273  +
        /* BuilderGenerator.kt:291 */
  170    274   
    }
  171         -
    /// <p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
         275  +
    /// /* BuilderGenerator.kt:312 */<p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
  172    276   
    /// <p>Valid values: <code>524288</code></p>
         277  +
    /* BuilderGenerator.kt:314 */
  173    278   
    pub fn set_data_length(mut self, input: ::std::option::Option<i32>) -> Self {
         279  +
        /* BuilderGenerator.kt:315 */
  174    280   
        self.data_length = input;
  175    281   
        self
         282  +
        /* BuilderGenerator.kt:314 */
  176    283   
    }
  177         -
    /// <p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
         284  +
    /// /* BuilderGenerator.kt:334 */<p>The size of the data to write to the block, in bytes. Currently, the only supported size is <code>524288</code>.</p>
  178    285   
    /// <p>Valid values: <code>524288</code></p>
         286  +
    /* BuilderGenerator.kt:336 */
  179    287   
    pub fn get_data_length(&self) -> &::std::option::Option<i32> {
         288  +
        /* BuilderGenerator.kt:337 */
  180    289   
        &self.data_length
         290  +
        /* BuilderGenerator.kt:336 */
  181    291   
    }
  182         -
    /// <p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
  183         -
    /// This field is required.
         292  +
    /// /* BuilderGenerator.kt:286 */<p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
         293  +
    /// /* BuilderGenerator.kt:288 */This field is required.
         294  +
    /* BuilderGenerator.kt:291 */
  184    295   
    pub fn checksum_algorithm(mut self, input: crate::types::ChecksumAlgorithm) -> Self {
         296  +
        /* BuilderGenerator.kt:292 */
  185    297   
        self.checksum_algorithm = ::std::option::Option::Some(input);
         298  +
        /* BuilderGenerator.kt:293 */
  186    299   
        self
         300  +
        /* BuilderGenerator.kt:291 */
  187    301   
    }
  188         -
    /// <p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
         302  +
    /// /* BuilderGenerator.kt:312 */<p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
         303  +
    /* BuilderGenerator.kt:314 */
  189    304   
    pub fn set_checksum_algorithm(mut self, input: ::std::option::Option<crate::types::ChecksumAlgorithm>) -> Self {
         305  +
        /* BuilderGenerator.kt:315 */
  190    306   
        self.checksum_algorithm = input;
  191    307   
        self
         308  +
        /* BuilderGenerator.kt:314 */
  192    309   
    }
  193         -
    /// <p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
         310  +
    /// /* BuilderGenerator.kt:334 */<p>The algorithm used to generate the checksum. Currently, the only supported algorithm is <code>SHA256</code>.</p>
         311  +
    /* BuilderGenerator.kt:336 */
  194    312   
    pub fn get_checksum_algorithm(&self) -> &::std::option::Option<crate::types::ChecksumAlgorithm> {
         313  +
        /* BuilderGenerator.kt:337 */
  195    314   
        &self.checksum_algorithm
         315  +
        /* BuilderGenerator.kt:336 */
  196    316   
    }
  197         -
    /// Consumes the builder and constructs a [`PutSnapshotBlockInput`](crate::operation::put_snapshot_block::PutSnapshotBlockInput).
         317  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`PutSnapshotBlockInput`](crate::operation::put_snapshot_block::PutSnapshotBlockInput).
         318  +
    /* BuilderGenerator.kt:253 */
  198    319   
    pub fn build(
  199    320   
        self,
  200    321   
    ) -> ::std::result::Result<crate::operation::put_snapshot_block::PutSnapshotBlockInput, ::aws_smithy_types::error::operation::BuildError> {
  201         -
        ::std::result::Result::Ok(crate::operation::put_snapshot_block::PutSnapshotBlockInput {
  202         -
            snapshot_id: self.snapshot_id,
  203         -
            block_index: self.block_index,
  204         -
            checksum: self.checksum,
  205         -
            progress: self.progress,
  206         -
            block_data: self.block_data.unwrap_or_default(),
  207         -
            data_length: self.data_length,
  208         -
            checksum_algorithm: self.checksum_algorithm,
  209         -
        })
  210         -
    }
         322  +
        /* BuilderGenerator.kt:254 */
         323  +
        ::std::result::Result::Ok(
         324  +
            /* BuilderGenerator.kt:477 */
         325  +
            crate::operation::put_snapshot_block::PutSnapshotBlockInput {
         326  +
                /* BuilderGenerator.kt:481 */ snapshot_id: self.snapshot_id,
         327  +
                /* BuilderGenerator.kt:481 */
         328  +
                block_index: self.block_index,
         329  +
                /* BuilderGenerator.kt:481 */
         330  +
                checksum: self.checksum,
         331  +
                /* BuilderGenerator.kt:481 */
         332  +
                progress: self.progress,
         333  +
                /* BuilderGenerator.kt:481 */
         334  +
                block_data: self
         335  +
                    .block_data
         336  +
                    /* BuilderGenerator.kt:487 */
         337  +
                    .unwrap_or_default(),
         338  +
                /* BuilderGenerator.kt:481 */
         339  +
                data_length: self.data_length,
         340  +
                /* BuilderGenerator.kt:481 */
         341  +
                checksum_algorithm: self.checksum_algorithm,
         342  +
                /* BuilderGenerator.kt:477 */
         343  +
            }, /* BuilderGenerator.kt:254 */
         344  +
        )
         345  +
        /* BuilderGenerator.kt:253 */
         346  +
    }
         347  +
    /* BuilderGenerator.kt:355 */
  211    348   
}
         349  +
/* BuilderGenerator.kt:379 */
  212    350   
impl ::std::fmt::Debug for PutSnapshotBlockInputBuilder {
         351  +
    /* BuilderGenerator.kt:380 */
  213    352   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         353  +
        /* BuilderGenerator.kt:381 */
  214    354   
        let mut formatter = f.debug_struct("PutSnapshotBlockInputBuilder");
         355  +
        /* BuilderGenerator.kt:395 */
  215    356   
        formatter.field("snapshot_id", &self.snapshot_id);
         357  +
        /* BuilderGenerator.kt:395 */
  216    358   
        formatter.field("block_index", &self.block_index);
         359  +
        /* BuilderGenerator.kt:395 */
  217    360   
        formatter.field("checksum", &self.checksum);
         361  +
        /* BuilderGenerator.kt:395 */
  218    362   
        formatter.field("progress", &self.progress);
         363  +
        /* BuilderGenerator.kt:395 */
  219    364   
        formatter.field("block_data", &"*** Sensitive Data Redacted ***");
         365  +
        /* BuilderGenerator.kt:395 */
  220    366   
        formatter.field("data_length", &self.data_length);
         367  +
        /* BuilderGenerator.kt:395 */
  221    368   
        formatter.field("checksum_algorithm", &self.checksum_algorithm);
         369  +
        /* BuilderGenerator.kt:400 */
  222    370   
        formatter.finish()
         371  +
        /* BuilderGenerator.kt:380 */
  223    372   
    }
         373  +
    /* BuilderGenerator.kt:379 */
  224    374   
}

tmp-codegen-diff/codegen-client-test/ebs/rust-client-codegen/src/operation/put_snapshot_block/_put_snapshot_block_output.rs

@@ -1,1 +71,119 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct PutSnapshotBlockOutput {
    6         -
    /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
           8  +
pub /* StructureGenerator.kt:201 */ struct PutSnapshotBlockOutput {
           9  +
    /// /* StructureGenerator.kt:231 */<p>The algorithm used by Amazon EBS to generate the checksum.</p>
    7     10   
    pub checksum_algorithm: ::std::option::Option<crate::types::ChecksumAlgorithm>,
    8         -
    /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          11  +
    /// /* StructureGenerator.kt:231 */<p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
    9     12   
    pub checksum: ::std::option::Option<::std::string::String>,
          13  +
    /* StructureGenerator.kt:201 */
   10     14   
}
          15  +
/* StructureGenerator.kt:135 */
   11     16   
impl PutSnapshotBlockOutput {
   12         -
    /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
          17  +
    /// /* StructureGenerator.kt:231 */<p>The algorithm used by Amazon EBS to generate the checksum.</p>
          18  +
    /* StructureGenerator.kt:166 */
   13     19   
    pub fn checksum_algorithm(&self) -> ::std::option::Option<&crate::types::ChecksumAlgorithm> {
          20  +
        /* StructureGenerator.kt:170 */
   14     21   
        self.checksum_algorithm.as_ref()
          22  +
        /* StructureGenerator.kt:166 */
   15     23   
    }
   16         -
    /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          24  +
    /// /* StructureGenerator.kt:231 */<p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          25  +
    /* StructureGenerator.kt:166 */
   17     26   
    pub fn checksum(&self) -> ::std::option::Option<&str> {
          27  +
        /* StructureGenerator.kt:169 */
   18     28   
        self.checksum.as_deref()
          29  +
        /* StructureGenerator.kt:166 */
   19     30   
    }
          31  +
    /* StructureGenerator.kt:135 */
   20     32   
}
          33  +
/* ClientCodegenVisitor.kt:237 */
   21     34   
impl PutSnapshotBlockOutput {
   22         -
    /// Creates a new builder-style object to manufacture [`PutSnapshotBlockOutput`](crate::operation::put_snapshot_block::PutSnapshotBlockOutput).
          35  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`PutSnapshotBlockOutput`](crate::operation::put_snapshot_block::PutSnapshotBlockOutput).
          36  +
    /* BuilderGenerator.kt:175 */
   23     37   
    pub fn builder() -> crate::operation::put_snapshot_block::builders::PutSnapshotBlockOutputBuilder {
          38  +
        /* BuilderGenerator.kt:176 */
   24     39   
        crate::operation::put_snapshot_block::builders::PutSnapshotBlockOutputBuilder::default()
          40  +
        /* BuilderGenerator.kt:175 */
   25     41   
    }
          42  +
    /* ClientCodegenVisitor.kt:237 */
   26     43   
}
   27     44   
   28         -
/// A builder for [`PutSnapshotBlockOutput`](crate::operation::put_snapshot_block::PutSnapshotBlockOutput).
          45  +
/// /* BuilderGenerator.kt:342 */A builder for [`PutSnapshotBlockOutput`](crate::operation::put_snapshot_block::PutSnapshotBlockOutput).
          46  +
/* RustType.kt:516 */
   29     47   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          48  +
/* RustType.kt:516 */
   30     49   
#[non_exhaustive]
          50  +
/* BuilderGenerator.kt:345 */
   31     51   
pub struct PutSnapshotBlockOutputBuilder {
   32         -
    pub(crate) checksum_algorithm: ::std::option::Option<crate::types::ChecksumAlgorithm>,
   33         -
    pub(crate) checksum: ::std::option::Option<::std::string::String>,
          52  +
    /* BuilderGenerator.kt:275 */ pub(crate) checksum_algorithm: ::std::option::Option<crate::types::ChecksumAlgorithm>,
          53  +
    /* BuilderGenerator.kt:275 */ pub(crate) checksum: ::std::option::Option<::std::string::String>,
          54  +
    /* BuilderGenerator.kt:345 */
   34     55   
}
          56  +
/* BuilderGenerator.kt:355 */
   35     57   
impl PutSnapshotBlockOutputBuilder {
   36         -
    /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
          58  +
    /// /* BuilderGenerator.kt:286 */<p>The algorithm used by Amazon EBS to generate the checksum.</p>
          59  +
    /* BuilderGenerator.kt:291 */
   37     60   
    pub fn checksum_algorithm(mut self, input: crate::types::ChecksumAlgorithm) -> Self {
          61  +
        /* BuilderGenerator.kt:292 */
   38     62   
        self.checksum_algorithm = ::std::option::Option::Some(input);
          63  +
        /* BuilderGenerator.kt:293 */
   39     64   
        self
          65  +
        /* BuilderGenerator.kt:291 */
   40     66   
    }
   41         -
    /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
          67  +
    /// /* BuilderGenerator.kt:312 */<p>The algorithm used by Amazon EBS to generate the checksum.</p>
          68  +
    /* BuilderGenerator.kt:314 */
   42     69   
    pub fn set_checksum_algorithm(mut self, input: ::std::option::Option<crate::types::ChecksumAlgorithm>) -> Self {
          70  +
        /* BuilderGenerator.kt:315 */
   43     71   
        self.checksum_algorithm = input;
   44     72   
        self
          73  +
        /* BuilderGenerator.kt:314 */
   45     74   
    }
   46         -
    /// <p>The algorithm used by Amazon EBS to generate the checksum.</p>
          75  +
    /// /* BuilderGenerator.kt:334 */<p>The algorithm used by Amazon EBS to generate the checksum.</p>
          76  +
    /* BuilderGenerator.kt:336 */
   47     77   
    pub fn get_checksum_algorithm(&self) -> &::std::option::Option<crate::types::ChecksumAlgorithm> {
          78  +
        /* BuilderGenerator.kt:337 */
   48     79   
        &self.checksum_algorithm
          80  +
        /* BuilderGenerator.kt:336 */
   49     81   
    }
   50         -
    /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          82  +
    /// /* BuilderGenerator.kt:286 */<p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          83  +
    /* BuilderGenerator.kt:291 */
   51     84   
    pub fn checksum(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
          85  +
        /* BuilderGenerator.kt:292 */
   52     86   
        self.checksum = ::std::option::Option::Some(input.into());
          87  +
        /* BuilderGenerator.kt:293 */
   53     88   
        self
          89  +
        /* BuilderGenerator.kt:291 */
   54     90   
    }
   55         -
    /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          91  +
    /// /* BuilderGenerator.kt:312 */<p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          92  +
    /* BuilderGenerator.kt:314 */
   56     93   
    pub fn set_checksum(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
          94  +
        /* BuilderGenerator.kt:315 */
   57     95   
        self.checksum = input;
   58     96   
        self
          97  +
        /* BuilderGenerator.kt:314 */
   59     98   
    }
   60         -
    /// <p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
          99  +
    /// /* BuilderGenerator.kt:334 */<p>The SHA256 checksum generated for the block data by Amazon EBS.</p>
         100  +
    /* BuilderGenerator.kt:336 */
   61    101   
    pub fn get_checksum(&self) -> &::std::option::Option<::std::string::String> {
         102  +
        /* BuilderGenerator.kt:337 */
   62    103   
        &self.checksum
         104  +
        /* BuilderGenerator.kt:336 */
   63    105   
    }
   64         -
    /// Consumes the builder and constructs a [`PutSnapshotBlockOutput`](crate::operation::put_snapshot_block::PutSnapshotBlockOutput).
         106  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`PutSnapshotBlockOutput`](crate::operation::put_snapshot_block::PutSnapshotBlockOutput).
         107  +
    /* BuilderGenerator.kt:253 */
   65    108   
    pub fn build(self) -> crate::operation::put_snapshot_block::PutSnapshotBlockOutput {
         109  +
        /* BuilderGenerator.kt:477 */
   66    110   
        crate::operation::put_snapshot_block::PutSnapshotBlockOutput {
   67         -
            checksum_algorithm: self.checksum_algorithm,
         111  +
            /* BuilderGenerator.kt:481 */ checksum_algorithm: self.checksum_algorithm,
         112  +
            /* BuilderGenerator.kt:481 */
   68    113   
            checksum: self.checksum,
         114  +
            /* BuilderGenerator.kt:477 */
   69    115   
        }
         116  +
        /* BuilderGenerator.kt:253 */
   70    117   
    }
         118  +
    /* BuilderGenerator.kt:355 */
   71    119   
}