pub struct IrProfileDto {
pub file_name: String,
pub label: String,
pub is_custom: bool,
pub is_in_use: bool,
}Expand description
Data transfer object describing a single cabinet impulse-response profile.
Instances are produced by [FileService::get_all_ir_profiles] and returned
Fields§
§file_name: String.wav filename as stored on disk (e.g. "vintage-4x12.wav").
This value is what gets stored inside [CabinetDto::ir_file_path] and
passed back to the backend when creating or restoring a Cabinet effect.
[CabinetDto::ir_file_path]: crate::domain::dto::effect::cabinet_dto::CabinetDto::ir_file_path
label: StringHuman-readable display name shown in the frontend dropdown.
Derived from file_name by stripping the .wav extension and replacing
hyphens and underscores with spaces (e.g. "vintage-4x12.wav" → "vintage 4x12").
is_custom: booltrue when this profile was uploaded by the user and lives in the custom IR
directory rather than the bundled resources/default_ir folder.
Only custom profiles may be removed; attempting to remove a default profile
returns an error from [remove_ir_profile].
[remove_ir_profile]: crate::commands::effect_commands::cabinet_ir::remove_ir_profile
is_in_use: booltrue when at least one Cabinet effect in any active channel currently
references this profile by file_name.
The frontend uses this to disable the remove-button and prevent deleting
an IR that is actively shaping the tone of a running effect chain.
Trait Implementations§
Source§impl Clone for IrProfileDto
impl Clone for IrProfileDto
Source§fn clone(&self) -> IrProfileDto
fn clone(&self) -> IrProfileDto
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for IrProfileDto
impl Debug for IrProfileDto
Source§impl<'de> Deserialize<'de> for IrProfileDto
impl<'de> Deserialize<'de> for IrProfileDto
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 IrProfileDto
impl PartialEq for IrProfileDto
Source§impl Serialize for IrProfileDto
impl Serialize for IrProfileDto
Source§impl TS for IrProfileDto
impl TS for IrProfileDto
Source§type WithoutGenerics = IrProfileDto
type WithoutGenerics = IrProfileDto
WithoutGenerics should just be Self.
If the type does have generic parameters, then all generic parameters must be replaced with
a dummy type, e.g ts_rs::Dummy or (). The only requirement for these dummy types is that
EXPORT_TO must be None. Read moreSource§type OptionInnerType = IrProfileDto
type OptionInnerType = IrProfileDto
std::option::Option<T>, then this associated type is set to T.
All other implementations of TS should set this type to Self instead.Source§fn docs() -> Option<String>
fn docs() -> Option<String>
TS is derived, docs are
automatically read from your doc comments or #[doc = ".."] attributesSource§fn decl_concrete(cfg: &Config) -> String
fn decl_concrete(cfg: &Config) -> String
TS::decl().
If this type is not generic, then this function is equivalent to TS::decl().Source§fn decl(cfg: &Config) -> String
fn decl(cfg: &Config) -> String
type User = { user_id: number, ... }.
This function will panic if the type has no declaration. Read moreSource§fn inline(cfg: &Config) -> String
fn inline(cfg: &Config) -> String
{ user_id: number }.
This function will panic if the type cannot be inlined.Source§fn inline_flattened(cfg: &Config) -> String
fn inline_flattened(cfg: &Config) -> String
Source§fn visit_generics(v: &mut impl TypeVisitor)where
Self: 'static,
fn visit_generics(v: &mut impl TypeVisitor)where
Self: 'static,
Source§fn output_path() -> Option<PathBuf>
fn output_path() -> Option<PathBuf>
T should be exported, relative to the output directory.
The returned path does not include any base directory. Read moreSource§fn visit_dependencies(v: &mut impl TypeVisitor)where
Self: 'static,
fn visit_dependencies(v: &mut impl TypeVisitor)where
Self: 'static,
§fn dependencies(cfg: &Config) -> Vec<Dependency>where
Self: 'static,
fn dependencies(cfg: &Config) -> Vec<Dependency>where
Self: 'static,
§fn export(cfg: &Config) -> Result<(), ExportError>where
Self: 'static,
fn export(cfg: &Config) -> Result<(), ExportError>where
Self: 'static,
TS::export_all]. Read more§fn export_all(cfg: &Config) -> Result<(), ExportError>where
Self: 'static,
fn export_all(cfg: &Config) -> Result<(), ExportError>where
Self: 'static,
TS::export]. Read more