Class BluetoothMeshProtocol
java.lang.Object
org.openremote.agent.protocol.AbstractProtocol<BluetoothMeshAgent,BluetoothMeshAgentLink>
org.openremote.agent.protocol.bluetooth.mesh.BluetoothMeshProtocol
- All Implemented Interfaces:
org.openremote.model.asset.agent.Protocol<BluetoothMeshAgent>
public class BluetoothMeshProtocol
extends AbstractProtocol<BluetoothMeshAgent,BluetoothMeshAgentLink>
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final Logger
static final String
static final String
static final String
Fields inherited from class org.openremote.agent.protocol.AbstractProtocol
agent, assetService, datapointService, dynamicAttributes, executorService, linkedAttributes, messageBrokerContext, predictedDatapointService, processorLock, producerTemplate, scheduledExecutorService, timerService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
addNetwork
(BluetoothMeshNetwork network) protected void
doLinkAttribute
(String assetId, org.openremote.model.attribute.Attribute<?> attribute, BluetoothMeshAgentLink agentLink) Link anAttribute
to its linkedAgent
.protected void
doLinkedAttributeWrite
(BluetoothMeshAgentLink agentLink, org.openremote.model.attribute.AttributeEvent event, Object processedValue) An Attribute event (write) has been requested for an attribute linked to this protocol.protected void
doStart
(org.openremote.model.Container container) Start this protocol instanceprotected void
doStop
(org.openremote.model.Container container) Stop this protocol instanceprotected void
doUnlinkAttribute
(String assetId, org.openremote.model.attribute.Attribute<?> attribute, BluetoothMeshAgentLink agentLink) Unlink anAttribute
from its linkedAgent
.Get a URI that describes this specific protocol instanceGet the name for this protocolstatic void
initMainThread
(ScheduledExecutorService scheduledExecutorService) Methods inherited from class org.openremote.agent.protocol.AbstractProtocol
getAgent, getLinkedAttributes, linkAttribute, onAgentAttributeChanged, processLinkedAttributeWrite, sendAttributeEvent, sendAttributeEvent, setAssetService, setConnectionStatus, start, stop, toString, unlinkAttribute, updateLinkedAttribute, updateLinkedAttribute
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.openremote.model.asset.agent.Protocol
prefixLogMessage
-
Field Details
-
PROTOCOL_DISPLAY_NAME
- See Also:
-
DEFAULT_MTU
public static final int DEFAULT_MTU- See Also:
-
DEFAULT_SEQUENCE_NUMBER
public static final int DEFAULT_SEQUENCE_NUMBER- See Also:
-
DEFAULT_NETWORK_KEY_INDEX
public static final int DEFAULT_NETWORK_KEY_INDEX- See Also:
-
DEFAULT_APPLICATION_KEY_INDEX
public static final int DEFAULT_APPLICATION_KEY_INDEX- See Also:
-
REGEXP_INDEX_AND_KEY
- See Also:
-
REGEXP_PROXY_ADDRESS
- See Also:
-
LOG
-
-
Constructor Details
-
BluetoothMeshProtocol
-
-
Method Details
-
initMainThread
-
addNetwork
-
getProtocolName
Description copied from interface:org.openremote.model.asset.agent.Protocol
Get the name for this protocol -
getProtocolInstanceUri
Description copied from interface:org.openremote.model.asset.agent.Protocol
Get a URI that describes this specific protocol instance -
doStart
Description copied from class:AbstractProtocol
Start this protocol instance- Specified by:
doStart
in classAbstractProtocol<BluetoothMeshAgent,
BluetoothMeshAgentLink> - Throws:
Exception
-
doStop
Description copied from class:AbstractProtocol
Stop this protocol instance- Specified by:
doStop
in classAbstractProtocol<BluetoothMeshAgent,
BluetoothMeshAgentLink> - Throws:
Exception
-
doLinkAttribute
protected void doLinkAttribute(String assetId, org.openremote.model.attribute.Attribute<?> attribute, BluetoothMeshAgentLink agentLink) throws RuntimeException Description copied from class:AbstractProtocol
Link anAttribute
to its linkedAgent
.- Specified by:
doLinkAttribute
in classAbstractProtocol<BluetoothMeshAgent,
BluetoothMeshAgentLink> - Throws:
RuntimeException
-
doUnlinkAttribute
protected void doUnlinkAttribute(String assetId, org.openremote.model.attribute.Attribute<?> attribute, BluetoothMeshAgentLink agentLink) Description copied from class:AbstractProtocol
Unlink anAttribute
from its linkedAgent
.- Specified by:
doUnlinkAttribute
in classAbstractProtocol<BluetoothMeshAgent,
BluetoothMeshAgentLink>
-
doLinkedAttributeWrite
protected void doLinkedAttributeWrite(BluetoothMeshAgentLink agentLink, org.openremote.model.attribute.AttributeEvent event, Object processedValue) Description copied from class:AbstractProtocol
An Attribute event (write) has been requested for an attribute linked to this protocol. The processedValue is the resulting value after applying standard outbound value processing (seeProtocolUtil.doOutboundValueProcessing(org.openremote.model.attribute.AttributeRef, org.openremote.model.asset.agent.AgentLink<?>, java.lang.Object, boolean, java.time.Instant)
). Protocol implementations should generally use the processedValue but may also choose to use the original value for some purpose if required.- Specified by:
doLinkedAttributeWrite
in classAbstractProtocol<BluetoothMeshAgent,
BluetoothMeshAgentLink>
-