diff options
Diffstat (limited to 'mingling/src/example_docs.rs')
| -rw-r--r-- | mingling/src/example_docs.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/mingling/src/example_docs.rs b/mingling/src/example_docs.rs index e3b9db6..e61551b 100644 --- a/mingling/src/example_docs.rs +++ b/mingling/src/example_docs.rs @@ -2064,6 +2064,7 @@ pub mod example_lazy_resources {} /// pub desc: String, /// } /// +/// // --------- IMPORTANT --------- /// /// Attach a `Description` to `EntryGreet`. /// /// /// /// - `BindType` = `EntryGreet` (the enum variant / entry type) @@ -2074,6 +2075,7 @@ pub mod example_lazy_resources {} /// desc: "ok".to_string(), /// } /// } +/// // --------- IMPORTANT --------- /// /// pack!(ResultName = String); /// pack!(DescResult = String); @@ -2094,10 +2096,12 @@ pub mod example_lazy_resources {} /// #[chain] /// fn handle_desc(_args: EntryDescription) -> Next { /// use mingling::ProgramCollect; +/// // --------- IMPORTANT --------- /// let msg = match ThisProgram::get_metadata::<Description>(ThisProgram::EntryGreet) { /// Some(d) => format!("EntryGreet desc = {}", d.desc), /// None => "EntryGreet has no description".to_string(), /// }; +/// // --------- IMPORTANT --------- /// DescResult::new(msg).to_render() /// } /// @@ -2105,10 +2109,12 @@ pub mod example_lazy_resources {} /// #[chain] /// fn handle_nodoc(_args: EntryNoDescription) -> Next { /// use mingling::ProgramCollect; +/// // --------- IMPORTANT --------- /// let msg = match ThisProgram::get_metadata::<Description>(ThisProgram::EntryDescription) { /// Some(d) => format!("EntryDescription desc = {}", d.desc), /// None => "EntryDescription has no description".to_string(), /// }; +/// // --------- IMPORTANT --------- /// DescResult::new(msg).to_render() /// } /// |
