Skip to content

armgit / core

Public Imported from GitHub
0

100% open-source IoT Platform - Integrate your devices, add intelligence, build custom apps

Minor

Christian Bauer696772a3815f
diff --git a/agent/src/main/java/org/openremote/agent3/protocol/AbstractProtocol.java b/agent/src/main/java/org/openremote/agent3/protocol/AbstractProtocol.java
index 50e087685..64c22707f 100644
--- a/agent/src/main/java/org/openremote/agent3/protocol/AbstractProtocol.java
+++ b/agent/src/main/java/org/openremote/agent3/protocol/AbstractProtocol.java
@@ -112,12 +112,12 @@ public abstract class AbstractProtocol implements Protocol {
}
@Override
- public void unlinkAttributes(String entityId) throws Exception {
+ public void unlinkAttributes(String thingId) throws Exception {
synchronized (linkedAttributes) {
Iterator<Map.Entry<AttributeRef, ThingAttribute>> entryIterator = linkedAttributes.entrySet().iterator();
while (entryIterator.hasNext()) {
Map.Entry<AttributeRef, ThingAttribute> entry = entryIterator.next();
- if (entry.getKey().getEntityId().equals(entityId)) {
+ if (entry.getKey().getEntityId().equals(thingId)) {
LOG.fine("Attribute moved on '" + getProtocolName() + "': " + entry.getValue());
onAttributeRemoved(entry.getValue());
entryIterator.remove();
diff --git a/agent/src/main/java/org/openremote/agent3/protocol/Protocol.java b/agent/src/main/java/org/openremote/agent3/protocol/Protocol.java
index d8eec63ae..ee5f376db 100644
--- a/agent/src/main/java/org/openremote/agent3/protocol/Protocol.java
+++ b/agent/src/main/java/org/openremote/agent3/protocol/Protocol.java
@@ -19,16 +19,13 @@
*/
package org.openremote.agent3.protocol;
-import org.openremote.model.asset.ThingAttribute;
import org.openremote.container.ContainerService;
+import org.openremote.model.asset.ThingAttribute;
import java.util.Collection;
-import java.util.logging.Logger;
public interface Protocol extends ContainerService {
- Logger LOG = Logger.getLogger(Protocol.class.getName());
-
// TODO: Some of these options should be configurable depending on expected load etc.
// Message topic for communicating from thing to protocol layer (thing attribute changed, trigger actuator)
@@ -41,6 +38,6 @@ public interface Protocol extends ContainerService {
void linkAttributes(Collection<ThingAttribute> attributes) throws Exception;
- void unlinkAttributes(String entityId) throws Exception;
+ void unlinkAttributes(String thingId) throws Exception;
}