aws_sdk_cloudtrail/operation/describe_query/
_describe_query_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 DescribeQueryInput {
6    /// <p>The ARN (or the ID suffix of the ARN) of an event data store on which the specified query was run.</p>
7    #[deprecated(note = "EventDataStore is no longer required by DescribeQueryRequest")]
8    pub event_data_store: ::std::option::Option<::std::string::String>,
9    /// <p>The query ID.</p>
10    pub query_id: ::std::option::Option<::std::string::String>,
11    /// <p>The alias that identifies a query template.</p>
12    pub query_alias: ::std::option::Option<::std::string::String>,
13    /// <p>The ID of the dashboard refresh.</p>
14    pub refresh_id: ::std::option::Option<::std::string::String>,
15    /// <p>The account ID of the event data store owner.</p>
16    pub event_data_store_owner_account_id: ::std::option::Option<::std::string::String>,
17}
18impl DescribeQueryInput {
19    /// <p>The ARN (or the ID suffix of the ARN) of an event data store on which the specified query was run.</p>
20    #[deprecated(note = "EventDataStore is no longer required by DescribeQueryRequest")]
21    pub fn event_data_store(&self) -> ::std::option::Option<&str> {
22        self.event_data_store.as_deref()
23    }
24    /// <p>The query ID.</p>
25    pub fn query_id(&self) -> ::std::option::Option<&str> {
26        self.query_id.as_deref()
27    }
28    /// <p>The alias that identifies a query template.</p>
29    pub fn query_alias(&self) -> ::std::option::Option<&str> {
30        self.query_alias.as_deref()
31    }
32    /// <p>The ID of the dashboard refresh.</p>
33    pub fn refresh_id(&self) -> ::std::option::Option<&str> {
34        self.refresh_id.as_deref()
35    }
36    /// <p>The account ID of the event data store owner.</p>
37    pub fn event_data_store_owner_account_id(&self) -> ::std::option::Option<&str> {
38        self.event_data_store_owner_account_id.as_deref()
39    }
40}
41impl DescribeQueryInput {
42    /// Creates a new builder-style object to manufacture [`DescribeQueryInput`](crate::operation::describe_query::DescribeQueryInput).
43    pub fn builder() -> crate::operation::describe_query::builders::DescribeQueryInputBuilder {
44        crate::operation::describe_query::builders::DescribeQueryInputBuilder::default()
45    }
46}
47
48/// A builder for [`DescribeQueryInput`](crate::operation::describe_query::DescribeQueryInput).
49#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
50#[non_exhaustive]
51pub struct DescribeQueryInputBuilder {
52    pub(crate) event_data_store: ::std::option::Option<::std::string::String>,
53    pub(crate) query_id: ::std::option::Option<::std::string::String>,
54    pub(crate) query_alias: ::std::option::Option<::std::string::String>,
55    pub(crate) refresh_id: ::std::option::Option<::std::string::String>,
56    pub(crate) event_data_store_owner_account_id: ::std::option::Option<::std::string::String>,
57}
58impl DescribeQueryInputBuilder {
59    /// <p>The ARN (or the ID suffix of the ARN) of an event data store on which the specified query was run.</p>
60    #[deprecated(note = "EventDataStore is no longer required by DescribeQueryRequest")]
61    pub fn event_data_store(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
62        self.event_data_store = ::std::option::Option::Some(input.into());
63        self
64    }
65    /// <p>The ARN (or the ID suffix of the ARN) of an event data store on which the specified query was run.</p>
66    #[deprecated(note = "EventDataStore is no longer required by DescribeQueryRequest")]
67    pub fn set_event_data_store(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
68        self.event_data_store = input;
69        self
70    }
71    /// <p>The ARN (or the ID suffix of the ARN) of an event data store on which the specified query was run.</p>
72    #[deprecated(note = "EventDataStore is no longer required by DescribeQueryRequest")]
73    pub fn get_event_data_store(&self) -> &::std::option::Option<::std::string::String> {
74        &self.event_data_store
75    }
76    /// <p>The query ID.</p>
77    pub fn query_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
78        self.query_id = ::std::option::Option::Some(input.into());
79        self
80    }
81    /// <p>The query ID.</p>
82    pub fn set_query_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
83        self.query_id = input;
84        self
85    }
86    /// <p>The query ID.</p>
87    pub fn get_query_id(&self) -> &::std::option::Option<::std::string::String> {
88        &self.query_id
89    }
90    /// <p>The alias that identifies a query template.</p>
91    pub fn query_alias(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
92        self.query_alias = ::std::option::Option::Some(input.into());
93        self
94    }
95    /// <p>The alias that identifies a query template.</p>
96    pub fn set_query_alias(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
97        self.query_alias = input;
98        self
99    }
100    /// <p>The alias that identifies a query template.</p>
101    pub fn get_query_alias(&self) -> &::std::option::Option<::std::string::String> {
102        &self.query_alias
103    }
104    /// <p>The ID of the dashboard refresh.</p>
105    pub fn refresh_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
106        self.refresh_id = ::std::option::Option::Some(input.into());
107        self
108    }
109    /// <p>The ID of the dashboard refresh.</p>
110    pub fn set_refresh_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
111        self.refresh_id = input;
112        self
113    }
114    /// <p>The ID of the dashboard refresh.</p>
115    pub fn get_refresh_id(&self) -> &::std::option::Option<::std::string::String> {
116        &self.refresh_id
117    }
118    /// <p>The account ID of the event data store owner.</p>
119    pub fn event_data_store_owner_account_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
120        self.event_data_store_owner_account_id = ::std::option::Option::Some(input.into());
121        self
122    }
123    /// <p>The account ID of the event data store owner.</p>
124    pub fn set_event_data_store_owner_account_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
125        self.event_data_store_owner_account_id = input;
126        self
127    }
128    /// <p>The account ID of the event data store owner.</p>
129    pub fn get_event_data_store_owner_account_id(&self) -> &::std::option::Option<::std::string::String> {
130        &self.event_data_store_owner_account_id
131    }
132    /// Consumes the builder and constructs a [`DescribeQueryInput`](crate::operation::describe_query::DescribeQueryInput).
133    pub fn build(
134        self,
135    ) -> ::std::result::Result<crate::operation::describe_query::DescribeQueryInput, ::aws_smithy_types::error::operation::BuildError> {
136        ::std::result::Result::Ok(crate::operation::describe_query::DescribeQueryInput {
137            event_data_store: self.event_data_store,
138            query_id: self.query_id,
139            query_alias: self.query_alias,
140            refresh_id: self.refresh_id,
141            event_data_store_owner_account_id: self.event_data_store_owner_account_id,
142        })
143    }
144}