Skip to main content

aws_sdk_omics/operation/get_read_set/
_get_read_set_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct GetReadSetInput {
6    /// <p>The read set's ID.</p>
7    pub id: ::std::option::Option<::std::string::String>,
8    /// <p>The read set's sequence store ID.</p>
9    pub sequence_store_id: ::std::option::Option<::std::string::String>,
10    /// <p>The file to retrieve.</p>
11    pub file: ::std::option::Option<crate::types::ReadSetFile>,
12    /// <p>The part number to retrieve.</p>
13    pub part_number: ::std::option::Option<i32>,
14}
15impl GetReadSetInput {
16    /// <p>The read set's ID.</p>
17    pub fn id(&self) -> ::std::option::Option<&str> {
18        self.id.as_deref()
19    }
20    /// <p>The read set's sequence store ID.</p>
21    pub fn sequence_store_id(&self) -> ::std::option::Option<&str> {
22        self.sequence_store_id.as_deref()
23    }
24    /// <p>The file to retrieve.</p>
25    pub fn file(&self) -> ::std::option::Option<&crate::types::ReadSetFile> {
26        self.file.as_ref()
27    }
28    /// <p>The part number to retrieve.</p>
29    pub fn part_number(&self) -> ::std::option::Option<i32> {
30        self.part_number
31    }
32}
33impl GetReadSetInput {
34    /// Creates a new builder-style object to manufacture [`GetReadSetInput`](crate::operation::get_read_set::GetReadSetInput).
35    pub fn builder() -> crate::operation::get_read_set::builders::GetReadSetInputBuilder {
36        crate::operation::get_read_set::builders::GetReadSetInputBuilder::default()
37    }
38}
39
40/// A builder for [`GetReadSetInput`](crate::operation::get_read_set::GetReadSetInput).
41#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
42#[non_exhaustive]
43pub struct GetReadSetInputBuilder {
44    pub(crate) id: ::std::option::Option<::std::string::String>,
45    pub(crate) sequence_store_id: ::std::option::Option<::std::string::String>,
46    pub(crate) file: ::std::option::Option<crate::types::ReadSetFile>,
47    pub(crate) part_number: ::std::option::Option<i32>,
48}
49impl GetReadSetInputBuilder {
50    /// <p>The read set's ID.</p>
51    /// This field is required.
52    pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
53        self.id = ::std::option::Option::Some(input.into());
54        self
55    }
56    /// <p>The read set's ID.</p>
57    pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
58        self.id = input;
59        self
60    }
61    /// <p>The read set's ID.</p>
62    pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
63        &self.id
64    }
65    /// <p>The read set's sequence store ID.</p>
66    /// This field is required.
67    pub fn sequence_store_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
68        self.sequence_store_id = ::std::option::Option::Some(input.into());
69        self
70    }
71    /// <p>The read set's sequence store ID.</p>
72    pub fn set_sequence_store_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
73        self.sequence_store_id = input;
74        self
75    }
76    /// <p>The read set's sequence store ID.</p>
77    pub fn get_sequence_store_id(&self) -> &::std::option::Option<::std::string::String> {
78        &self.sequence_store_id
79    }
80    /// <p>The file to retrieve.</p>
81    pub fn file(mut self, input: crate::types::ReadSetFile) -> Self {
82        self.file = ::std::option::Option::Some(input);
83        self
84    }
85    /// <p>The file to retrieve.</p>
86    pub fn set_file(mut self, input: ::std::option::Option<crate::types::ReadSetFile>) -> Self {
87        self.file = input;
88        self
89    }
90    /// <p>The file to retrieve.</p>
91    pub fn get_file(&self) -> &::std::option::Option<crate::types::ReadSetFile> {
92        &self.file
93    }
94    /// <p>The part number to retrieve.</p>
95    /// This field is required.
96    pub fn part_number(mut self, input: i32) -> Self {
97        self.part_number = ::std::option::Option::Some(input);
98        self
99    }
100    /// <p>The part number to retrieve.</p>
101    pub fn set_part_number(mut self, input: ::std::option::Option<i32>) -> Self {
102        self.part_number = input;
103        self
104    }
105    /// <p>The part number to retrieve.</p>
106    pub fn get_part_number(&self) -> &::std::option::Option<i32> {
107        &self.part_number
108    }
109    /// Consumes the builder and constructs a [`GetReadSetInput`](crate::operation::get_read_set::GetReadSetInput).
110    pub fn build(self) -> ::std::result::Result<crate::operation::get_read_set::GetReadSetInput, ::aws_smithy_types::error::operation::BuildError> {
111        ::std::result::Result::Ok(crate::operation::get_read_set::GetReadSetInput {
112            id: self.id,
113            sequence_store_id: self.sequence_store_id,
114            file: self.file,
115            part_number: self.part_number,
116        })
117    }
118}