app_data.rs (513B)
1 #![forbid(unsafe_code)] 2 3 use crate::envelope::kind::KIND_APP_DATA as KIND_APP_DATA_EVENT; 4 5 #[cfg(not(feature = "std"))] 6 use alloc::string::String; 7 8 pub const KIND_APP_DATA: u32 = KIND_APP_DATA_EVENT; 9 10 #[cfg_attr(all(test, feature = "std"), derive(dto_bindgen::Dto))] 11 #[cfg_attr(all(test, feature = "std"), dto(export))] 12 #[cfg_attr( 13 any(feature = "serde", test), 14 derive(serde::Serialize, serde::Deserialize) 15 )] 16 #[derive(Clone, Debug)] 17 pub struct AppData { 18 pub d_tag: String, 19 pub content: String, 20 }