Valetudo/backend/lib/core/capabilities/DoNotDisturbCapability.js

35 lines
844 B
JavaScript

const Capability = require("./Capability");
const NotImplementedError = require("../NotImplementedError");
/**
* @template {import("../ValetudoRobot")} T
* @extends Capability<T>
*/
class DoNotDisturbCapability extends Capability {
/**
*
* @abstract
* @returns {Promise<import("../../entities/core/ValetudoDNDConfiguration")>}
*/
async getDndConfiguration() {
throw new NotImplementedError();
}
/**
* @abstract
* @param {import("../../entities/core/ValetudoDNDConfiguration")} dndConfig
* @returns {Promise<void>}
*/
async setDndConfiguration(dndConfig) {
throw new NotImplementedError();
}
getType() {
return DoNotDisturbCapability.TYPE;
}
}
DoNotDisturbCapability.TYPE = "DoNotDisturbCapability";
module.exports = DoNotDisturbCapability;