@manuth/woltlab-compiler
Version:
A compiler for generating WoltLab-Package `.tar` Archives and other WoltLab-Package Components
51 lines (50 loc) • 1.89 kB
TypeScript
import { InstructionCompiler } from "../../../Compilation/PackageSystem/Instructions/InstructionCompiler.js";
import { LocalizationItem } from "../../../Globalization/LocalizationItem.js";
import { Node } from "../../../NodeSystem/Node.js";
import { INodeSystemInstructionOptions } from "../NodeSystem/INodeSystemInstructionOptions.js";
import { NodeSystemInstruction } from "../NodeSystem/NodeSystemInstruction.js";
import { ILocalizationInstruction } from "./ILocalizationInstruction.js";
/**
* Represents an instruction which provides localizations.
*
* @template TItem
* The type of the localization-items.
*
* @template TOptions
* THe type of the options for generating the localization-items.
*/
export declare abstract class LocalizationInstruction<TItem extends LocalizationItem, TOptions> extends NodeSystemInstruction<TItem, TOptions> implements ILocalizationInstruction {
/**
* The name of the type of localization instructions.
*/
static readonly LOCALIZATION_INSTRUCTION_TYPE = "language";
/**
* Initializes a new instance of the {@link LocalizationInstruction `LocalizationInstruction<TItem, TOptions>`} class.
*
* @param options
* The options for generating the object.
*
* @param generator
* The generator-function for generating sub-nodes.
*/
constructor(options: INodeSystemInstructionOptions<TOptions>, generator: (node: Node<TItem, TOptions>, options: TOptions) => TItem);
/**
* @inheritdoc
*/
get Type(): string;
/**
* @inheritdoc
*/
get TranslationDirectory(): string;
/**
* @inheritdoc
*/
get Compiler(): InstructionCompiler<ILocalizationInstruction>;
/**
* @inheritdoc
*
* @returns
* The messages of the options-instruction.
*/
GetMessages(): Record<string, Record<string, Record<string, string>>>;
}