import { ByteVector } from "../../byteVector"; import { Frame, FrameClassType } from "./frame"; import { Id3v2FrameHeader } from "./frameHeader"; import { FrameIdentifier } from "../frameIdentifiers"; /** * Fallback type when no other frame class works for a given frame. */ export default class UnknownFrame extends Frame { private constructor(); /** * Constructs and initializes a new instance with a specified type * @param identifier ID3v2 frame identifier * @param data Contents of the frame */ static fromData(identifier: FrameIdentifier, data?: ByteVector): UnknownFrame; /** * Constructs and initializes a new instance by reading its raw data in a specified ID3v2 * version. This method allows for offset reading from the data byte vector. * @param data Raw representation of the new frame * @param offset What offset in `data` the frame actually begins. Must be positive, * safe integer * @param header Header of the frame found at `data` in the data * @param version ID3v2 version the frame was originally encoded with */ static fromOffsetRawData(data: ByteVector, offset: number, header: Id3v2FrameHeader, version: number): UnknownFrame; /** * Constructs and initializes a new instance by reading its raw data in a specified * ID3v2 version. * @param data Raw representation of the new frame * @param version ID3v2 version the raw frame is encoded with, must be a positive 8-bit integer */ static fromRawData(data: ByteVector, version: number): UnknownFrame; /** @inheritDoc */ get frameClassType(): FrameClassType; /** * Gets and sets the field data in the current instance */ data: ByteVector; /** @inheritDoc */ clone(): Frame; /** @inheritDoc */ protected parseFields(data: ByteVector): void; /** @inheritDoc */ protected renderFields(): ByteVector; }