import { AppObject, AppObjectEntity, Handler } from "@vived/core";
export interface RequestHandler {
    readonly requestType: string;
    payloadVersion: number;
    handleRequest: (version: number, payload?: unknown) => void;
}
export declare abstract class AppHandlerEntity extends AppObjectEntity {
    static readonly type = "APP_HANDLER_ENTITY";
    abstract handler: Handler;
    abstract registerRequestHandler: (requestHandler: RequestHandler) => void;
}
export declare function makeAppHandler(appObject: AppObject): AppHandlerEntity;
export declare class UnsupportedRequestVersion extends Error {
    constructor(requestType: string, version: number);
}
export declare class UnableToParsePayload extends Error {
    constructor(requestType: string, version: number, payload: string);
}
//# sourceMappingURL=AppHandler.d.ts.map