Skip to main content

Host

Trait Host 

Source
pub trait Host {
    // Required methods
    fn function(&mut self, name: &str, args: &[Value]) -> Option<Result<Value>>;
    fn command(&mut self, name: &str, args: &[Value]) -> Option<Result<Flow>>;
}
Expand description

系のデータを読む関数・命令を差し込む口。知らない名前には None を返す

Required Methods§

Source

fn function(&mut self, name: &str, args: &[Value]) -> Option<Result<Value>>

関数(名前は大文字)。例: CURV(3)

Source

fn command(&mut self, name: &str, args: &[Value]) -> Option<Result<Flow>>

命令(名前は大文字)。例: RAYTRACE 0, 1, 0, 1

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§