From 8a0b01720f5618ae06cfce67dac6dde2916d5705 Mon Sep 17 00:00:00 2001 From: Nicolas Gaud Date: Wed, 11 Mar 2020 16:26:59 +0100 Subject: [PATCH] Using ConcurrentMap interface instead of implementation --- .../sarl/io/sarl/sre/services/context/SpaceRepository.sarl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sre/io.janusproject/io.janusproject.plugin/src/main/sarl/io/sarl/sre/services/context/SpaceRepository.sarl b/sre/io.janusproject/io.janusproject.plugin/src/main/sarl/io/sarl/sre/services/context/SpaceRepository.sarl index 9e2cc6756c..4071799e06 100644 --- a/sre/io.janusproject/io.janusproject.plugin/src/main/sarl/io/sarl/sre/services/context/SpaceRepository.sarl +++ b/sre/io.janusproject/io.janusproject.plugin/src/main/sarl/io/sarl/sre/services/context/SpaceRepository.sarl @@ -53,6 +53,7 @@ import java.util.EventListener import java.util.UUID import java.util.concurrent.ConcurrentHashMap import java.util.concurrent.ConcurrentLinkedDeque +import java.util.concurrent.ConcurrentMap import java.util.concurrent.ConcurrentSkipListSet import java.util.concurrent.TimeUnit import java.util.logging.Logger @@ -108,7 +109,7 @@ abstract class SpaceRepository implements SpaceListener { /** Replies the internal map that contains the spaces */ - protected abstract def getSharedStructure : ConcurrentHashMap + protected abstract def getSharedStructure : ConcurrentMap /** Create a space description. * @@ -173,7 +174,7 @@ abstract class SpaceRepository implements SpaceListener { return defaultSpace } - private def createSpaceFirstInstance(spec : Class>, spaceID : SpaceID, + protected def createSpaceFirstInstance(spec : Class>, spaceID : SpaceID, creationParams : Object[]) : S with S extends Space { assert spaceID.spaceSpecification === null || spaceID.spaceSpecification == spec, "The specification type is invalid"