provided interface now sets its own unique id.
[utils] / system / general / src / main / java / org / wamblee / system / core / DefaultScope.java
index 51949ca1570df5dd755a905edb1a4e5049a92a71..18f26cc8d0a1e8ddaa75a3b88affd2c81422bf5b 100644 (file)
@@ -81,10 +81,8 @@ public class DefaultScope implements Scope {
        @Override
        synchronized public void publishInterface(ProvidedInterface aInterface,
                        Object aImplementation) {
-               String id = UUID.randomUUID().toString();
-               _provided.put(id, new ProvidedInterfaceImplementation(aInterface,
+               _provided.put(aInterface.getUniqueId(), new ProvidedInterfaceImplementation(aInterface,
                                aImplementation));
-               aInterface.setUniqueId(id);
        }
 
        @Override