UNPKG

@ekamjotsingh.ek/energy-management-system

Version:
34 lines (29 loc) 922 B
/** * Class representing a smart HVAC system. */ class HVACSystem { hvacID: string; buildingID: string; /** * Create an HVACSystem instance. * @param hvacID - Unique identifier for the HVAC system. * @param buildingID - Identifier for the building where the HVAC system is installed. */ constructor(hvacID: string, buildingID: string) { this.hvacID = hvacID; this.buildingID = buildingID; } /** * Simulate controlling the temperature. */ controlTemperature(): void { console.log(`Controlling temperature with HVAC system ${this.hvacID} in building ${this.buildingID}.`); } /** * Simulate scheduling maintenance for the HVAC system. */ scheduleMaintenance(): void { console.log(`Scheduling maintenance for HVAC system ${this.hvacID}.`); } } export default HVACSystem;