--- a/CachingRegistry.st Mon Sep 19 08:39:59 2016 +0100
+++ b/CachingRegistry.st Mon Sep 19 08:46:27 2016 +0100
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
"
COPYRIGHT (c) 1999 by eXept Software AG
All Rights Reserved
@@ -63,6 +65,22 @@
"
! !
+!CachingRegistry methodsFor:'enumerating'!
+
+detect:aBlock ifNone:exceptionValue
+ "... additionaly move it to the front of the LRU chain"
+
+ keyArray validElementsDo:[:obj |
+ (obj ~~ DeletedEntry and:[aBlock value:obj]) ifTrue:[
+ keptReferences
+ removeIdentical:obj ifAbsent:[];
+ addLast:obj.
+ ^ obj
+ ].
+ ].
+ ^ exceptionValue value
+! !
+
!CachingRegistry methodsFor:'private'!
cacheSize:aNumber