/**
 * Error types for device communication
 */
export declare const ERROR_TYPES: {
    readonly ECONNRESET: "ECONNRESET";
    readonly ECONNREFUSED: "ECONNREFUSED";
    readonly EADDRINUSE: "EADDRINUSE";
    readonly ETIMEDOUT: "ETIMEDOUT";
};
type ErrorType = keyof typeof ERROR_TYPES;
interface ErrorInfo {
    message: string;
    code?: ErrorType | string;
}
interface ZkErrorDetails {
    err: {
        message: string;
        code?: string;
    };
    ip: string;
    command: string | number;
}
/**
 * Custom error class for device communication errors
 */
export declare class ZkError {
    private err;
    private ip;
    private command;
    /**
     * Creates a new ZkError instance
     * @param err The error object
     * @param command The command that caused the error
     * @param ip The IP address of the device
     */
    constructor(err: ErrorInfo, command: number | string, ip: string);
    /**
     * Gets a user-friendly error message
     * @returns A formatted error message
     */
    toast(): string;
    /**
     * Gets detailed error information
     * @returns An object containing error details
     */
    getError(): ZkErrorDetails;
}
declare const _default: {
    ZkError: typeof ZkError;
    ERROR_TYPES: {
        readonly ECONNRESET: "ECONNRESET";
        readonly ECONNREFUSED: "ECONNREFUSED";
        readonly EADDRINUSE: "EADDRINUSE";
        readonly ETIMEDOUT: "ETIMEDOUT";
    };
};
export default _default;
