--- a/SnapShotImage.st Thu Aug 23 10:33:10 2001 +0200
+++ b/SnapShotImage.st Wed Sep 05 18:45:04 2001 +0200
@@ -1,7 +1,7 @@
"{ Package: 'stx:libtool2' }"
Object subclass:#SnapShotImage
- instanceVariableNames:'memory globals'
+ instanceVariableNames:'memory globals cachedBehaviors'
classVariableNames:''
poolDictionaries:''
category:'System-Support'
@@ -71,19 +71,24 @@
!SnapShotImage methodsFor:'smalltalk protocol'!
allClassesDo:aBlock
- self keysAndValuesDo:[:key :valRef |
- valRef isInteger ifFalse:[
- valRef ~~ true ifTrue:[
- valRef ~~ false ifTrue:[
- valRef notNil ifTrue:[
- valRef isImageBehavior ifTrue:[
- aBlock value:valRef
+ cachedBehaviors isNil ifTrue:[
+ cachedBehaviors := OrderedCollection new.
+
+ self keysAndValuesDo:[:key :valRef |
+ valRef isInteger ifFalse:[
+ valRef ~~ true ifTrue:[
+ valRef ~~ false ifTrue:[
+ valRef notNil ifTrue:[
+ valRef isImageBehavior ifTrue:[
+ cachedBehaviors add:valRef
+ ]
]
]
]
]
- ]
+ ].
].
+ cachedBehaviors do:aBlock
!
allClassesInCategory:aCategory