SimpleClass
homey.simple_class
This is a simple class with log functions.
Ancestors
- homey.util.event_emitter.EventEmitter
- typing.Generic
Subclasses
- App
- BleAdvertisement
- BleCharacteristic
- BleDescriptor
- BlePeripheral
- BleService
- CloudOAuth2Callback
- CloudWebhook
- Device
- DiscoveryResult
- DiscoveryStrategy
- Driver
- FlowArgument
- FlowCard
- Homey
- Manager
- Signal
- Widget
- WidgetSetting
- ZigbeeNode
- ZWaveCommandClass
- ZWaveNode
Methods
log
def log(self, *args: Any) ‑> NoneLog the given arguments, emitting a __log event.
error
def error(self, *args: Any) ‑> NoneLog the given arguments, emitting an __error event.
debug
def debug(self, *args: Any) ‑> NoneLog the given arguments, emitting a __debug event.
on_log
def on_log(self, f: Callable[..., None]) ‑> SelfThe __log event is fired when the SimpleClass.log() method is called.
Args
| Name | Type | Description |
|---|---|---|
f |
Callable[..., None] | A callback that receives the positional arguments passed to SimpleClass.log() |
on_error
def on_error(self, f: Callable[..., None]) ‑> SelfThe __error event is fired when the SimpleClass.error() method is called.
Args
| Name | Type | Description |
|---|---|---|
f |
Callable[..., None] | A callback that receives the positional arguments passed to SimpleClass.error() |
on_debug
def on_debug(self, f: Callable[..., None]) ‑> SelfThe __debug event is fired when the SimpleClass.debug() method is called.
Args
| Name | Type | Description |
|---|---|---|
f |
Callable[..., None] | A callback that receives the positional arguments passed to SimpleClass.debug() |