UNPKG

@picovoice/cheetah-web

Version:

Cheetah Speech-to-Text engine for web browsers (via WebAssembly)

48 lines 2.61 kB
import { PvError } from "@picovoice/web-utils"; import { PvStatus } from "./types"; declare class CheetahError extends Error { private readonly _status; private readonly _shortMessage; private readonly _messageStack; constructor(status: PvStatus, message: string, messageStack?: string[], pvError?: PvError | null); get status(): PvStatus; get shortMessage(): string; get messageStack(): string[]; private static errorToString; } declare class CheetahOutOfMemoryError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahIOError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahInvalidArgumentError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahStopIterationError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahKeyError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahInvalidStateError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahRuntimeError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahActivationError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahActivationLimitReachedError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahActivationThrottledError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } declare class CheetahActivationRefusedError extends CheetahError { constructor(message: string, messageStack?: string[], pvError?: PvError | null); } export { CheetahError, CheetahOutOfMemoryError, CheetahIOError, CheetahInvalidArgumentError, CheetahStopIterationError, CheetahKeyError, CheetahInvalidStateError, CheetahRuntimeError, CheetahActivationError, CheetahActivationLimitReachedError, CheetahActivationThrottledError, CheetahActivationRefusedError, }; export declare function pvStatusToException(pvStatus: PvStatus, errorMessage: string, messageStack?: string[], pvError?: PvError | null): CheetahError; //# sourceMappingURL=cheetah_errors.d.ts.map