/** @packageDocumentation Ogg Speex file format handler. Reads and writes XiphComment tags and Speex audio properties. */ import { IOStream } from "../../toolkit/ioStream.js"; import { ReadStyle } from "../../toolkit/types.js"; import { XiphComment } from "../xiphComment.js"; import { OggFile } from "../oggFile.js"; import { SpeexProperties } from "./speexProperties.js"; /** * Implementation of an Ogg Speex file. * * Packet 0 — Speex identification header (for audio properties). * Packet 1 — XiphComment data with framing bit (like Vorbis). */ export declare class OggSpeexFile extends OggFile { /** The XiphComment tag parsed from packet 1, or a fresh empty tag if absent. */ private _tag; /** Parsed Speex audio properties, or `null` if not yet read. */ private _properties; /** * Number of header packets in a Speex stream (identification + comment). * @returns `2` */ protected get numHeaderPackets(): number; /** * Private constructor — use {@link OggSpeexFile.open} to create instances. * @param stream - The underlying I/O stream for the Speex file. */ private constructor(); /** * Open and parse an Ogg Speex file from the given stream. * @param stream - The I/O stream to read from. * @param readProperties - Whether to parse audio properties. Defaults to `true`. * @param readStyle - Level of detail for audio property parsing. Defaults to `ReadStyle.Average`. * @returns A fully initialised `OggSpeexFile` instance. */ static open(stream: IOStream, readProperties?: boolean, readStyle?: ReadStyle): Promise; /** * Returns the XiphComment tag for this file. * @returns The {@link XiphComment} providing access to all Speex comment fields. */ tag(): XiphComment; /** * Returns the audio properties parsed from the Speex identification header. * @returns The {@link SpeexProperties}, or `null` if `readProperties` was `false` on open. */ audioProperties(): SpeexProperties | null; /** * Writes the current XiphComment tag back to the stream as packet 1. * @returns `true` on success, `false` if the file is read-only. */ save(): Promise; /** * Reads tags and (optionally) audio properties from the stream. * @param readProperties - Whether to parse audio properties. * @param readStyle - Level of detail for audio property parsing. */ private read; } //# sourceMappingURL=speexFile.d.ts.map