@vertigis/viewer-spec
Version:
VertiGIS Viewer Specification
26 lines (25 loc) • 779 B
TypeScript
import type { Command } from "./Command.js";
import type { MessageBus } from "./MessageBus.js";
/**
* A registry of well-known commands.
*/
export declare abstract class CommandRegistry {
protected readonly _messages: MessageBus;
/**
* Command name prefix that will be added to all commands in this registry.
*/
protected abstract readonly _prefix: string;
/**
* Creates a registry.
*
* @param messages The message bus to use.
*/
constructor(messages: MessageBus);
/**
* Returns the command corresponding to the given unqualified name.
*
* @param name The name of the command without the common prefix associated
* with this registry.
*/
protected _get<T = void>(name: string): Command<T>;
}