8eb64f883f
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
21 lines
725 B
Swift
21 lines
725 B
Swift
// RF64WriterError.swift
|
|
// Lyrebird
|
|
//
|
|
// Copyright (c) 2026 Joshua Parmenter / realizedsound
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
import Foundation
|
|
|
|
/// Errors thrown by ``RF64Writer``.
|
|
public enum RF64WriterError: Error {
|
|
/// The output file could not be created at the given URL.
|
|
case cannotCreateFile(URL)
|
|
/// A `FileHandle` write failed; carries the underlying error.
|
|
case writeFailed(Error)
|
|
/// Seeking back to patch the `ds64` sizes on ``RF64Writer/close()`` failed.
|
|
case seekFailed(Error)
|
|
/// The format passed to ``RF64Writer/init(url:format:sampleRate:channels:)`` is not
|
|
/// an RF64 case. Only `.rf64Float32` / `.rf64Int24` are supported.
|
|
case unsupportedFormat(AudioFileFormat)
|
|
}
|