aws_sdk_cloudtrail/operation/cancel_query/
_cancel_query_input.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct CancelQueryInput {
6 #[deprecated(note = "EventDataStore is no longer required by CancelQueryRequest")]
8 pub event_data_store: ::std::option::Option<::std::string::String>,
9 pub query_id: ::std::option::Option<::std::string::String>,
11 pub event_data_store_owner_account_id: ::std::option::Option<::std::string::String>,
13}
14impl CancelQueryInput {
15 #[deprecated(note = "EventDataStore is no longer required by CancelQueryRequest")]
17 pub fn event_data_store(&self) -> ::std::option::Option<&str> {
18 self.event_data_store.as_deref()
19 }
20 pub fn query_id(&self) -> ::std::option::Option<&str> {
22 self.query_id.as_deref()
23 }
24 pub fn event_data_store_owner_account_id(&self) -> ::std::option::Option<&str> {
26 self.event_data_store_owner_account_id.as_deref()
27 }
28}
29impl CancelQueryInput {
30 pub fn builder() -> crate::operation::cancel_query::builders::CancelQueryInputBuilder {
32 crate::operation::cancel_query::builders::CancelQueryInputBuilder::default()
33 }
34}
35
36#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
38#[non_exhaustive]
39pub struct CancelQueryInputBuilder {
40 pub(crate) event_data_store: ::std::option::Option<::std::string::String>,
41 pub(crate) query_id: ::std::option::Option<::std::string::String>,
42 pub(crate) event_data_store_owner_account_id: ::std::option::Option<::std::string::String>,
43}
44impl CancelQueryInputBuilder {
45 #[deprecated(note = "EventDataStore is no longer required by CancelQueryRequest")]
47 pub fn event_data_store(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
48 self.event_data_store = ::std::option::Option::Some(input.into());
49 self
50 }
51 #[deprecated(note = "EventDataStore is no longer required by CancelQueryRequest")]
53 pub fn set_event_data_store(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
54 self.event_data_store = input;
55 self
56 }
57 #[deprecated(note = "EventDataStore is no longer required by CancelQueryRequest")]
59 pub fn get_event_data_store(&self) -> &::std::option::Option<::std::string::String> {
60 &self.event_data_store
61 }
62 pub fn query_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
65 self.query_id = ::std::option::Option::Some(input.into());
66 self
67 }
68 pub fn set_query_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
70 self.query_id = input;
71 self
72 }
73 pub fn get_query_id(&self) -> &::std::option::Option<::std::string::String> {
75 &self.query_id
76 }
77 pub fn event_data_store_owner_account_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
79 self.event_data_store_owner_account_id = ::std::option::Option::Some(input.into());
80 self
81 }
82 pub fn set_event_data_store_owner_account_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
84 self.event_data_store_owner_account_id = input;
85 self
86 }
87 pub fn get_event_data_store_owner_account_id(&self) -> &::std::option::Option<::std::string::String> {
89 &self.event_data_store_owner_account_id
90 }
91 pub fn build(self) -> ::std::result::Result<crate::operation::cancel_query::CancelQueryInput, ::aws_smithy_types::error::operation::BuildError> {
93 ::std::result::Result::Ok(crate::operation::cancel_query::CancelQueryInput {
94 event_data_store: self.event_data_store,
95 query_id: self.query_id,
96 event_data_store_owner_account_id: self.event_data_store_owner_account_id,
97 })
98 }
99}