List of usage examples for org.apache.commons.collections4.map ReferenceMap ReferenceMap
public ReferenceMap(final ReferenceStrength keyType, final ReferenceStrength valueType, final boolean purgeValues)
ReferenceMap
that will use the specified types of references. From source file:org.jspresso.framework.model.entity.basic.BasicEntityRegistry.java
@SuppressWarnings("unchecked") private Map<Serializable, IEntity> createContractStoreMap() { return new ReferenceMap(AbstractReferenceMap.ReferenceStrength.HARD, AbstractReferenceMap.ReferenceStrength.WEAK, true); }
From source file:org.jspresso.framework.util.remote.registry.BasicRemotePeerRegistry.java
/** * Constructs a new {@code BasicRemotePeerRegistry} instance. *//*w w w . j av a2 s . c o m*/ @SuppressWarnings("unchecked") public BasicRemotePeerRegistry() { backingStore = new RemotePeerReferenceMap(AbstractReferenceMap.ReferenceStrength.WEAK, AbstractReferenceMap.ReferenceStrength.WEAK, true); automationBackingStore = new ReferenceMap(AbstractReferenceMap.ReferenceStrength.WEAK, AbstractReferenceMap.ReferenceStrength.WEAK, true); automationIndices = new HashMap<>(); setAutomationEnabled(false); }
From source file:org.jspresso.framework.util.resources.server.ResourceManager.java
@SuppressWarnings("unchecked") private ResourceManager() { // resources = new HashMap<String, IResource>(); resources = new ReferenceMap(AbstractReferenceMap.ReferenceStrength.SOFT, AbstractReferenceMap.ReferenceStrength.SOFT, true); random = new SecureRandom(); }