@npmstuff/argdown-core
Version:
A pluggable parser for the Argdown argumentation syntax
27 lines (26 loc) • 1.11 kB
TypeScript
import { ArgdownTreeWalker } from "./ArgdownTreeWalker";
import { IArgdownLogger } from "./IArgdownLogger";
import { IArgdownPlugin } from "./IArgdownPlugin";
import { IArgdownRequest, IArgdownResponse } from "./index";
export interface IArgdownProcessor {
plugins: IArgdownPlugin[];
walker: ArgdownTreeWalker | null;
}
export declare class ArgdownApplication {
processors: {
[name: string]: IArgdownProcessor;
};
logger: IArgdownLogger;
defaultLogger: IArgdownLogger;
defaultProcesses: {
[name: string]: string[];
};
constructor(logger?: IArgdownLogger);
addPlugin(plugin: IArgdownPlugin, processorId?: string): void;
removePlugin(plugin: IArgdownPlugin, processorId?: string): void;
replacePlugin(oldPluginId: string, newPlugin: IArgdownPlugin, processorId?: string): void;
getPlugins(processorId: string): IArgdownPlugin[] | null;
getPlugin(name: string, processorId: string): IArgdownPlugin | null;
removeProcessor(processorId: string): void;
run(request: IArgdownRequest, response?: IArgdownResponse): IArgdownResponse;
}