UNPKG

woltlab-compiler

Version:

A compiler for WoltLab-Package Archives and WoltLab-Package Components

46 lines 1.41 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const CronJobInstructionCompiler_1 = require("../../../Compilation/PackageSystem/Instructions/CronJobInstructionCompiler"); const CronJob_1 = require("../../../Tasks/CronJob"); const NamedDeleteInstruction_1 = require("../NamedDeleteInstruction"); /** * Represents an instruction which install cron-jobs. */ class CronJobInstruction extends NamedDeleteInstruction_1.NamedDeleteInstruction { /** * Initializes a new instance of the `CronJobInstruction` class. */ constructor(options) { super(options); /** * The cron-jobs provided by the instruction. */ this.cronJobs = []; for (let cronJob of options.CronJobs) { this.CronJobs.push(new CronJob_1.CronJob(cronJob)); } } /** * @inheritdoc */ get Type() { return "cronjob"; } /** * Gets or sets the cron-jobs provided by the instruction. */ get CronJobs() { return this.cronJobs; } set CronJobs(value) { this.cronJobs = value; } /** * @inheritdoc */ get Compiler() { return new CronJobInstructionCompiler_1.CronJobInstructionCompiler(this); } } exports.CronJobInstruction = CronJobInstruction; //# sourceMappingURL=CronJobInstruction.js.map