import { Resources } from '../resources/Resources.ts';
import { FastGlobOptions, FilesOption } from './deriveGlobOptions.ts';
interface ComponentV1Config {
    files: string | string[] | FilesOption;
    /** @deprecated */ path?: string;
    urlPath?: string;
    /** @deprecated */ root?: string;
    [key: string]: any;
}
interface ComponentV1Module {
    setupDirectory?: (urlPath: string, absolutePath: string, resources: Resources) => Promise<undefined | boolean>;
    handleDirectory?: (urlPath: string, absolutePath: string, resources: Resources) => Promise<undefined | boolean>;
    setupFile?: (contents: Buffer, urlPath: string, absolutePath: string, resources: Resources) => Promise<void>;
    handleFile?: (contents: Buffer, urlPath: string, absolutePath: string, resources: Resources) => Promise<void>;
}
interface ComponentV1Details {
    config: ComponentV1Config;
    name: string;
    directory: string;
    module: ComponentV1Module;
    resources: Resources;
}
export declare class ComponentV1 {
    readonly config: Readonly<ComponentV1Config>;
    readonly name: string;
    readonly directory: string;
    readonly module: Readonly<ComponentV1Module>;
    readonly resources: Resources;
    readonly globOptions: FastGlobOptions;
    readonly patternBases: string[];
    readonly baseURLPath: string;
    constructor(options: ComponentV1Details);
}
export declare class ComponentV1ProcessingError extends Error {
    constructor(message: string, component: ComponentV1Details);
}
export declare class InvalidFilesOptionError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
export declare class InvalidFilesSourceOptionError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
export declare class InvalidFilesOnlyOptionError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
export declare class InvalidFileIgnoreOptionError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
export declare class InvalidGlobPattern extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details, pattern: string);
}
export declare class InvalidRootOptionError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
export declare class InvalidRootOptionUseError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
export declare class InvalidPathOptionError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
export declare class InvalidURLPathOptionError extends ComponentV1ProcessingError {
    constructor(component: ComponentV1Details);
}
/**
 * Process a Resource Extension component by evaluating the files glob pattern
 * and then calling the appropriate setup/handle functions.
 */
export declare function processResourceExtensionComponent(component: ComponentV1): Promise<boolean>;
export {};
