Compare commits

...

2 Commits

Author SHA1 Message Date
Jan Scheiper
304c97bdcf added version 2020-08-06 00:18:48 +02:00
Jan Scheiper
992c5cba10 added deinit() method 2020-08-06 00:04:35 +02:00

View File

@ -21,6 +21,10 @@ class HCControlBase extends EventEmitter {
return true; return true;
} }
static get version() {
return "n/a";
}
get state() { get state() {
return this._state.clone(); return this._state.clone();
} }
@ -41,6 +45,14 @@ class HCControlBase extends EventEmitter {
return Promise.resolve(); return Promise.resolve();
} }
/**
* Run some sort of asynchronous de-initialization/cleanup
* @returns A promise which resolves when the de-initialization is complete
*/
deinit() {
return Promise.resolve();
}
/** /**
* Updates the state by polling the controlled device * Updates the state by polling the controlled device
* @returns A promise which resolves when the state has been pulled * @returns A promise which resolves when the state has been pulled