#[non_exhaustive]pub struct CaseEmptyRequest {
pub data: CaseEmpty,
pub additional_properties: BTreeMap<String, Value>,
/* private fields */
}
Expand description
Case empty request
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.data: CaseEmpty
Case empty request data
additional_properties: BTreeMap<String, Value>
Implementations§
Source§impl CaseEmptyRequest
impl CaseEmptyRequest
Sourcepub fn new(data: CaseEmpty) -> CaseEmptyRequest
pub fn new(data: CaseEmpty) -> CaseEmptyRequest
Examples found in repository?
examples/v2_case-management_ArchiveCase.rs (line 12)
9async fn main() {
10 // there is a valid "case" in the system
11 let case_id = std::env::var("CASE_ID").unwrap();
12 let body = CaseEmptyRequest::new(CaseEmpty::new(CaseResourceType::CASE));
13 let configuration = datadog::Configuration::new();
14 let api = CaseManagementAPI::with_config(configuration);
15 let resp = api.archive_case(case_id.clone(), body).await;
16 if let Ok(value) = resp {
17 println!("{:#?}", value);
18 } else {
19 println!("{:#?}", resp.unwrap_err());
20 }
21}
More examples
examples/v2_case-management_UnassignCase.rs (line 12)
9async fn main() {
10 // there is a valid "case" in the system
11 let case_id = std::env::var("CASE_ID").unwrap();
12 let body = CaseEmptyRequest::new(CaseEmpty::new(CaseResourceType::CASE));
13 let configuration = datadog::Configuration::new();
14 let api = CaseManagementAPI::with_config(configuration);
15 let resp = api.unassign_case(case_id.clone(), body).await;
16 if let Ok(value) = resp {
17 println!("{:#?}", value);
18 } else {
19 println!("{:#?}", resp.unwrap_err());
20 }
21}
examples/v2_case-management_UnarchiveCase.rs (line 12)
9async fn main() {
10 // there is a valid "case" in the system
11 let case_id = std::env::var("CASE_ID").unwrap();
12 let body = CaseEmptyRequest::new(CaseEmpty::new(CaseResourceType::CASE));
13 let configuration = datadog::Configuration::new();
14 let api = CaseManagementAPI::with_config(configuration);
15 let resp = api.unarchive_case(case_id.clone(), body).await;
16 if let Ok(value) = resp {
17 println!("{:#?}", value);
18 } else {
19 println!("{:#?}", resp.unwrap_err());
20 }
21}
pub fn additional_properties(self, value: BTreeMap<String, Value>) -> Self
Trait Implementations§
Source§impl Clone for CaseEmptyRequest
impl Clone for CaseEmptyRequest
Source§fn clone(&self) -> CaseEmptyRequest
fn clone(&self) -> CaseEmptyRequest
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for CaseEmptyRequest
impl Debug for CaseEmptyRequest
Source§impl<'de> Deserialize<'de> for CaseEmptyRequest
impl<'de> Deserialize<'de> for CaseEmptyRequest
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for CaseEmptyRequest
impl PartialEq for CaseEmptyRequest
Source§impl Serialize for CaseEmptyRequest
impl Serialize for CaseEmptyRequest
impl StructuralPartialEq for CaseEmptyRequest
Auto Trait Implementations§
impl Freeze for CaseEmptyRequest
impl RefUnwindSafe for CaseEmptyRequest
impl Send for CaseEmptyRequest
impl Sync for CaseEmptyRequest
impl Unpin for CaseEmptyRequest
impl UnwindSafe for CaseEmptyRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more