pub struct Description {
pub id: String,
pub name: String,
pub description: String,
pub actions: Vec<ActionDecl>,
pub device_actions: Vec<DeviceActionDecl>,
pub signals: Vec<SignalDecl>,
pub settings: Vec<SettingDecl>,
pub choices: Vec<ChoicesDecl>,
pub permissions: Vec<PermissionDecl>,
}Expand description
Everything static about an addon.
Fields§
§id: StringStable identifier, stored in bindings.
name: StringWhat to call it.
description: StringWhat it integrates, in a sentence.
actions: Vec<ActionDecl>Everything it can be asked to do.
device_actions: Vec<DeviceActionDecl>Everything it names that the device does on its own (ADR-0021).
Omitted when empty, which is almost always, and the omission is
load-bearing in the same way permissions’ is: an addon built against
SDK 1.0 sends no field, and declares none is exactly the right reading
of that. The reverse — a 1.1 addon talking to a 1.0 daemon — is the case
the version number cannot express, and is answered in
run rather than here.
signals: Vec<SignalDecl>Everything it publishes.
settings: Vec<SettingDecl>Everything it needs configuring.
choices: Vec<ChoicesDecl>Named lists its parameters draw options from (ADR-0022).
Omitted when empty, which is every addon that has none — and an addon built against an older SDK sends no field, which reads correctly as “declares none”.
permissions: Vec<PermissionDecl>Everything it needs to be allowed to do (FR-046).
Omitted when empty, which is the ordinary case — and the omission is load-bearing rather than tidy: an addon built against an older SDK sends no field, and “declares nothing” is exactly the right reading of that.
Trait Implementations§
Source§impl Clone for Description
impl Clone for Description
Source§fn clone(&self) -> Description
fn clone(&self) -> Description
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Description
impl Debug for Description
Source§impl<'de> Deserialize<'de> for Description
impl<'de> Deserialize<'de> for Description
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>,
Source§impl PartialEq for Description
impl PartialEq for Description
Source§fn eq(&self, other: &Description) -> bool
fn eq(&self, other: &Description) -> bool
self and other values to be equal, and is used by ==.