aws_sdk_apigateway/operation/get_model/
_get_model_output.rs1#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct GetModelOutput {
7 pub id: ::std::option::Option<::std::string::String>,
9 pub name: ::std::option::Option<::std::string::String>,
11 pub description: ::std::option::Option<::std::string::String>,
13 pub schema: ::std::option::Option<::std::string::String>,
15 pub content_type: ::std::option::Option<::std::string::String>,
17 _request_id: Option<String>,
18}
19impl GetModelOutput {
20 pub fn id(&self) -> ::std::option::Option<&str> {
22 self.id.as_deref()
23 }
24 pub fn name(&self) -> ::std::option::Option<&str> {
26 self.name.as_deref()
27 }
28 pub fn description(&self) -> ::std::option::Option<&str> {
30 self.description.as_deref()
31 }
32 pub fn schema(&self) -> ::std::option::Option<&str> {
34 self.schema.as_deref()
35 }
36 pub fn content_type(&self) -> ::std::option::Option<&str> {
38 self.content_type.as_deref()
39 }
40}
41impl ::aws_types::request_id::RequestId for GetModelOutput {
42 fn request_id(&self) -> Option<&str> {
43 self._request_id.as_deref()
44 }
45}
46impl GetModelOutput {
47 pub fn builder() -> crate::operation::get_model::builders::GetModelOutputBuilder {
49 crate::operation::get_model::builders::GetModelOutputBuilder::default()
50 }
51}
52
53#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
55#[non_exhaustive]
56pub struct GetModelOutputBuilder {
57 pub(crate) id: ::std::option::Option<::std::string::String>,
58 pub(crate) name: ::std::option::Option<::std::string::String>,
59 pub(crate) description: ::std::option::Option<::std::string::String>,
60 pub(crate) schema: ::std::option::Option<::std::string::String>,
61 pub(crate) content_type: ::std::option::Option<::std::string::String>,
62 _request_id: Option<String>,
63}
64impl GetModelOutputBuilder {
65 pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
67 self.id = ::std::option::Option::Some(input.into());
68 self
69 }
70 pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
72 self.id = input;
73 self
74 }
75 pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
77 &self.id
78 }
79 pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
81 self.name = ::std::option::Option::Some(input.into());
82 self
83 }
84 pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
86 self.name = input;
87 self
88 }
89 pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
91 &self.name
92 }
93 pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
95 self.description = ::std::option::Option::Some(input.into());
96 self
97 }
98 pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
100 self.description = input;
101 self
102 }
103 pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
105 &self.description
106 }
107 pub fn schema(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
109 self.schema = ::std::option::Option::Some(input.into());
110 self
111 }
112 pub fn set_schema(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
114 self.schema = input;
115 self
116 }
117 pub fn get_schema(&self) -> &::std::option::Option<::std::string::String> {
119 &self.schema
120 }
121 pub fn content_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
123 self.content_type = ::std::option::Option::Some(input.into());
124 self
125 }
126 pub fn set_content_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
128 self.content_type = input;
129 self
130 }
131 pub fn get_content_type(&self) -> &::std::option::Option<::std::string::String> {
133 &self.content_type
134 }
135 pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
136 self._request_id = Some(request_id.into());
137 self
138 }
139
140 pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
141 self._request_id = request_id;
142 self
143 }
144 pub fn build(self) -> crate::operation::get_model::GetModelOutput {
146 crate::operation::get_model::GetModelOutput {
147 id: self.id,
148 name: self.name,
149 description: self.description,
150 schema: self.schema,
151 content_type: self.content_type,
152 _request_id: self._request_id,
153 }
154 }
155}