nominal_api/conjure/objects/authentication/api/
dismiss_coachmark_request.rs1#[derive(
3 Debug,
4 Clone,
5 conjure_object::serde::Serialize,
6 conjure_object::serde::Deserialize,
7 PartialEq,
8 Eq,
9 PartialOrd,
10 Ord,
11 Hash
12)]
13#[serde(crate = "conjure_object::serde")]
14#[conjure_object::private::staged_builder::staged_builder]
15#[builder(crate = conjure_object::private::staged_builder, update, inline)]
16pub struct DismissCoachmarkRequest {
17 #[builder(into)]
18 #[serde(rename = "coachmarkId")]
19 coachmark_id: String,
20 #[builder(into)]
21 #[serde(rename = "appVersion")]
22 app_version: String,
23 #[builder(default, into)]
24 #[serde(rename = "stepIndex", skip_serializing_if = "Option::is_none", default)]
25 step_index: Option<i32>,
26}
27impl DismissCoachmarkRequest {
28 #[inline]
30 pub fn new(coachmark_id: impl Into<String>, app_version: impl Into<String>) -> Self {
31 Self::builder().coachmark_id(coachmark_id).app_version(app_version).build()
32 }
33 #[inline]
35 pub fn coachmark_id(&self) -> &str {
36 &*self.coachmark_id
37 }
38 #[inline]
40 pub fn app_version(&self) -> &str {
41 &*self.app_version
42 }
43 #[inline]
45 pub fn step_index(&self) -> Option<i32> {
46 self.step_index.as_ref().map(|o| *o)
47 }
48}