pub struct PresetRef {
pub uuid: String,
pub uri: String,
pub name: String,
pub category: Option<String>,
pub author: Option<String>,
pub comment: Option<String>,
pub tags: Vec<String>,
pub default: bool,
pub scope: PresetScope,
pub path: PathBuf,
}Expand description
One discovered preset: display metadata plus where to load it
from. The state blob is not held here - hosts enumerate far
more presets than they load, so the file is re-read lazily at
load time via load_preset_file.
Fields§
§uuid: StringStable identity from the preset’s metadata. Survives file rename, move, and recategorise; empty for files authored without one.
uri: Stringtruce-preset://<vendor>/<plugin>/<uuid> - see preset_uri.
name: StringHuman-readable name (from metadata, not the filename).
category: Option<String>Explicit metadata category, falling back to the preset’s
parent directory name within its scope root. None when
neither exists.
comment: Option<String>§default: boolThe library’s “init sound” marker from the metadata.
scope: PresetScope§path: PathBufAbsolute path to the on-disk file.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PresetRef
impl RefUnwindSafe for PresetRef
impl Send for PresetRef
impl Sync for PresetRef
impl Unpin for PresetRef
impl UnsafeUnpin for PresetRef
impl UnwindSafe for PresetRef
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