2023-01-27 00:36:06 +00:00
|
|
|
use std::collections::HashMap;
|
|
|
|
|
|
|
|
use serde::{Deserialize, Serialize};
|
|
|
|
|
2023-02-15 21:51:01 +00:00
|
|
|
#[derive(Serialize, Deserialize, Default, Debug, Clone)]
|
2023-01-27 00:36:06 +00:00
|
|
|
pub struct DocsGlobal {
|
|
|
|
pub documentation: String,
|
|
|
|
pub keys: HashMap<String, String>,
|
|
|
|
pub learn_more_link: String,
|
|
|
|
pub code_sample: String,
|
|
|
|
}
|
|
|
|
|
2023-02-15 21:51:01 +00:00
|
|
|
#[derive(Serialize, Deserialize, Default, Debug, Clone)]
|
2023-01-27 00:36:06 +00:00
|
|
|
pub struct DocsFunctionParamLink {
|
|
|
|
pub name: String,
|
|
|
|
pub documentation: String,
|
|
|
|
}
|
|
|
|
|
2023-02-15 21:51:01 +00:00
|
|
|
#[derive(Serialize, Deserialize, Default, Debug, Clone)]
|
2023-01-27 00:36:06 +00:00
|
|
|
pub struct DocsFunction {
|
|
|
|
#[serde(skip)]
|
|
|
|
pub global_name: String,
|
|
|
|
pub documentation: String,
|
|
|
|
pub params: Vec<DocsFunctionParamLink>,
|
|
|
|
pub returns: Vec<String>,
|
|
|
|
pub learn_more_link: String,
|
|
|
|
pub code_sample: String,
|
|
|
|
}
|
|
|
|
|
2023-02-15 21:51:01 +00:00
|
|
|
#[derive(Serialize, Deserialize, Default, Debug, Clone)]
|
2023-01-27 00:36:06 +00:00
|
|
|
pub struct DocsParam {
|
|
|
|
#[serde(skip)]
|
|
|
|
pub global_name: String,
|
|
|
|
#[serde(skip)]
|
|
|
|
pub function_name: String,
|
|
|
|
pub documentation: String,
|
|
|
|
}
|
|
|
|
|
2023-02-15 21:51:01 +00:00
|
|
|
#[derive(Serialize, Deserialize, Default, Debug, Clone)]
|
2023-01-27 00:36:06 +00:00
|
|
|
pub struct DocsReturn {
|
|
|
|
#[serde(skip)]
|
|
|
|
pub global_name: String,
|
|
|
|
#[serde(skip)]
|
|
|
|
pub function_name: String,
|
|
|
|
pub documentation: String,
|
|
|
|
}
|