UNPKG

u-he-preset-randomizer

Version:

Create random u-he synth presets through randomization and merging of your existing presets.

51 lines (50 loc) 1.55 kB
/** * @file Preset validation utilities. * Provides utilities for validating u-he preset files (.h2p format). * Useful for tests and general preset validation. */ /** * Validates that a preset file exists and is readable */ export declare function validatePresetFileExists(filePath: string): boolean; /** * Validates that a preset file has the correct extension */ export declare function validatePresetExtension(filePath: string): boolean; /** * Validates that a preset file has content */ export declare function validatePresetHasContent(filePath: string): boolean; /** * Validates that a preset can be parsed and is valid */ export declare function validatePresetParsable(filePath: string, binary?: boolean): boolean; /** * Comprehensive preset validation * * Validates that: * - File exists and is readable * - File has .h2p extension * - File has content * - File can be parsed successfully * - Preset passes validation checks */ export declare function validatePreset(filePath: string, binary?: boolean): boolean; /** * Validates multiple preset files * * @returns Object with validation results */ export declare function validatePresets(filePaths: string[], binary?: boolean): { valid: string[]; invalid: string[]; total: number; }; /** * Finds all .h2p preset files in a directory (recursive) */ export declare function findPresetFiles(dir: string): string[]; /** * Gets the newest preset files by modification time */ export declare function getNewestPresetFiles(dir: string, count: number): string[];