/// <reference types="node" />
import { REPLServer } from 'repl';
import { ReplContract, Handler, ContextOptions } from '@ioc:Adonis/Addons/Repl';
import { Compiler as TsCompiler } from '@adonisjs/require-ts/build/src/Compiler';
/**
 * Exposes the API to work the REPL server
 */
export declare class Repl implements ReplContract {
    private tsCompiler?;
    private historyFilePath?;
    /**
     * Compiler to compile REPL input
     */
    private compiler;
    /**
     * Length of the longest custom method name. We need to show a
     * symmetric view of custom methods and their description
     */
    private longestCustomMethodName;
    /**
     * Set of registered ready callbacks
     */
    private onReadyCallbacks;
    /**
     * A set of registered custom methods
     */
    private customMethods;
    /**
     * Reference to the underlying REPL server. Available
     * after `start` is invoked.
     */
    server: REPLServer;
    /**
     * Reference to the colors to print colorful messages
     */
    colors: import("@poppinss/colors/build/src/Base").Colors;
    constructor(tsCompiler?: TsCompiler | undefined, historyFilePath?: string | undefined);
    /**
     * Find if the error is recoverable or not
     */
    private isRecoverableError;
    /**
     * Custom eval method to execute the user code
     */
    private eval;
    private registerCustomMethodWithContext;
    /**
     * Register custom methods with the server context
     */
    private registerCustomMethodsWithContext;
    /**
     * Setup context with default globals
     */
    private setupContext;
    /**
     * Setup history file
     */
    private setupHistory;
    /**
     * Prints the welcome message
     */
    private printWelcomeMessage;
    /**
     * Prints the help for the custom methods
     */
    private printCustomMethodsHelp;
    /**
     * Prints the help for the context properties
     */
    private printContextHelp;
    /**
     * Prints the context to the console
     */
    private ls;
    /**
     * Notify by writing to the console
     */
    notify(message: string): void;
    /**
     * Start the REPL session
     */
    start(): this;
    /**
     * Register a callback to be invoked once the server is ready
     */
    ready(callback: (repl: ReplContract) => void): this;
    /**
     * Register a custom loader function to be added to the context
     */
    addMethod(name: string, handler: Handler, options?: ContextOptions): this;
}
