Package io.openems.edge.bridge.mbus
Class BridgeMbusImpl
java.lang.Object
io.openems.edge.common.component.AbstractOpenemsComponent
io.openems.edge.bridge.mbus.BridgeMbusImpl
- All Implemented Interfaces:
BridgeMbus
,OpenemsComponent
,org.osgi.service.event.EventHandler
public class BridgeMbusImpl
extends AbstractOpenemsComponent
implements BridgeMbus, org.osgi.service.event.EventHandler, OpenemsComponent
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.openems.edge.bridge.mbus.api.BridgeMbus
BridgeMbus.ChannelId
Nested classes/interfaces inherited from interface io.openems.edge.common.component.OpenemsComponent
OpenemsComponent.ChannelId
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
activate
(org.osgi.service.component.ComponentContext context, io.openems.edge.bridge.mbus.Config config) void
Add a Task.protected void
Handles @Deactivate of implementations.org.openmuc.jmbus.MBusConnection
Get theMBusConnection
.void
handleEvent
(org.osgi.service.event.Event event) void
removeTask
(String sourceId) Remove the task with the given Source-ID.Methods inherited from class io.openems.edge.common.component.AbstractOpenemsComponent
_channel, activate, activate, addChannel, addChannels, addChannels, alias, channels, getComponentContext, id, isEnabled, logDebug, logError, logInfo, logWarn, modified, removeChannel
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.openems.edge.common.component.OpenemsComponent
_channel, _getChannelAs, alias, channel, channel, channels, debugLog, getComponentContext, getState, getStateChannel, hasFaults, id, isEnabled, serviceFactoryPid, servicePid
-
Constructor Details
-
BridgeMbusImpl
public BridgeMbusImpl()
-
-
Method Details
-
activate
protected void activate(org.osgi.service.component.ComponentContext context, io.openems.edge.bridge.mbus.Config config) -
deactivate
protected void deactivate()Description copied from class:AbstractOpenemsComponent
Handles @Deactivate of implementations. Prints log output.- Overrides:
deactivate
in classAbstractOpenemsComponent
-
handleEvent
public void handleEvent(org.osgi.service.event.Event event) - Specified by:
handleEvent
in interfaceorg.osgi.service.event.EventHandler
-
getmBusConnection
public org.openmuc.jmbus.MBusConnection getmBusConnection()Description copied from interface:BridgeMbus
Get theMBusConnection
.- Specified by:
getmBusConnection
in interfaceBridgeMbus
- Returns:
- the
MBusConnection
-
addTask
Description copied from interface:BridgeMbus
Add a Task.- Specified by:
addTask
in interfaceBridgeMbus
- Parameters:
sourceId
- the Source-IDtask
- theMbusTask
-
removeTask
Description copied from interface:BridgeMbus
Remove the task with the given Source-ID.- Specified by:
removeTask
in interfaceBridgeMbus
- Parameters:
sourceId
- the Source-ID
-