Trait df_plugin::Action

source ·
pub trait Action {
    fn title(&mut self) -> String;
    fn name(&mut self) -> String;
    fn index(&mut self, header: JsonValue, request: JsonValue, db: Db) -> Response;

    fn token(&mut self) -> bool { ... }
    fn params(&mut self) -> JsonValue { ... }
    fn _check(&mut self, request: JsonValue) -> (bool, String, JsonValue) { ... }
    fn run(&mut self, header: JsonValue, request: JsonValue, db: Db) -> Response { ... }
    fn success(&mut self, code: i32, data: JsonValue, msg: &str) -> Response { ... }
    fn fail(&mut self, code: i32, data: JsonValue, msg: &str) -> Response { ... }
}
Expand description

动作

Required Methods§

标题

api名称

Provided Methods§

是否使用密钥

请求参数入口

检测

执行参数入口

Implementors§