/** * node-liblzma - Node.js bindings for liblzma * Copyright (C) Olivier Orabona * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see . */ /** * Base class for all LZMA-related errors */ export declare class LZMAError extends Error { readonly errno: number; readonly code: number; constructor(message: string, errno: number); } /** * Memory allocation error - thrown when LZMA cannot allocate required memory */ export declare class LZMAMemoryError extends LZMAError { constructor(errno: number); } /** * Memory limit error - thrown when operation would exceed memory usage limit */ export declare class LZMAMemoryLimitError extends LZMAError { constructor(errno: number); } /** * Format error - thrown when file format is not recognized */ export declare class LZMAFormatError extends LZMAError { constructor(errno: number); } /** * Options error - thrown when invalid or unsupported options are provided */ export declare class LZMAOptionsError extends LZMAError { constructor(errno: number, message?: string); } /** * Data error - thrown when compressed data is corrupt */ export declare class LZMADataError extends LZMAError { constructor(errno: number); } /** * Buffer error - thrown when no progress is possible (e.g., buffer too small) */ export declare class LZMABufferError extends LZMAError { constructor(errno: number); } /** * Programming error - thrown when there's an internal programming error */ export declare class LZMAProgrammingError extends LZMAError { constructor(errno: number); } /** * Factory function to create appropriate error instance based on errno */ export declare const LZMA_OK = 0; export declare const LZMA_STREAM_END = 1; export declare const LZMA_NO_CHECK = 2; export declare const LZMA_UNSUPPORTED_CHECK = 3; export declare const LZMA_GET_CHECK = 4; export declare const LZMA_MEM_ERROR = 5; export declare const LZMA_MEMLIMIT_ERROR = 6; export declare const LZMA_FORMAT_ERROR = 7; export declare const LZMA_OPTIONS_ERROR = 8; export declare const LZMA_DATA_ERROR = 9; export declare const LZMA_BUF_ERROR = 10; export declare const LZMA_PROG_ERROR = 11; export declare function createLZMAError(errno: number, message?: string): LZMAError; //# sourceMappingURL=errors.d.ts.map