class PluginRegistry

Plugin registry for managing loaded plugins

Constructors

new
PluginRegistry(logger?: ILogger)

Creates a new PluginRegistry

Properties

private
readonly
downloaders: Map<string, DownloaderPlugin>
private
readonly
logger: ILogger
private
readonly
plugins: Map<string, Plugin>
private
readonly
transformations: Map<string, TransformationPlugin>

Methods

clear(): Promise<void>

Clears all registered plugins

getDownloader(url: string): DownloaderPlugin | undefined

Gets a downloader for a URL scheme

getPlugin(name: string): Plugin | undefined

Gets a specific plugin by name

Gets all registered plugins

getTransformation(type: string): TransformationPlugin | undefined

Gets a custom transformation

hasTransformation(type: string): boolean

Checks if a transformation is available

Lists all registered plugins

listSchemes(): string[]

Lists all registered URL schemes

listTransformations(): { type: string; name: string; isCustom: boolean; }[]

Lists all available transformations (built-in + custom)

register(plugin: Plugin): Promise<void>

Registers a plugin

unregister(name: string): Promise<void>

Unregisters a plugin