pub struct ToolMeta {
pub name: String,
pub version: String,
pub mode: String,
}Expand description
Tool identification for the sensor report.
§Examples
use tokmd_envelope::ToolMeta;
let meta = ToolMeta::new("my-sensor", "0.1.0", "analyze");
assert_eq!(meta.name, "my-sensor");
// Shortcut for tokmd tools
let tokmd = ToolMeta::tokmd("1.5.0", "cockpit");
assert_eq!(tokmd.name, "tokmd");
assert_eq!(tokmd.mode, "cockpit");Fields§
§name: StringTool name (e.g., “tokmd”).
version: StringTool version (e.g., “1.5.0”).
mode: StringOperation mode (e.g., “cockpit”, “analyze”).
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ToolMeta
impl<'de> Deserialize<'de> for ToolMeta
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ToolMeta
impl RefUnwindSafe for ToolMeta
impl Send for ToolMeta
impl Sync for ToolMeta
impl Unpin for ToolMeta
impl UnsafeUnpin for ToolMeta
impl UnwindSafe for ToolMeta
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more