Skip to content

Commit

Permalink
[Enh]: Registry - Make Enumerable
Browse files Browse the repository at this point in the history
  • Loading branch information
seandenigris committed Jun 4, 2024
1 parent cfe9842 commit 077e3ec
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/SmallWorld-Core/SmallProject.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ SmallProject >> isObsoleteDescription [

{ #category : #testing }
SmallProject >> isPrivate [
^ isPrivate
^ self maLazyInstVarUsing: self isPrivateDescription
]

{ #category : #accessing }
Expand Down
9 changes: 8 additions & 1 deletion src/SmallWorld-Core/SmallProjectRegistry.class.st
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
Class {
#name : #SmallProjectRegistry,
#superclass : #Object,
#traits : 'PeTEnumerable',
#classTraits : 'PeTEnumerable classTrait',
#instVars : [
'projects'
],
Expand Down Expand Up @@ -77,6 +79,11 @@ SmallProjectRegistry >> printOn: aStream [
nextPutAll: ' projects'
]

{ #category : #enumerating }
SmallProjectRegistry >> privateEnumerable [
^ self projects
]

{ #category : #accessing }
SmallProjectRegistry >> projects [
^ projects ifNil: [ projects := SortedCollection sortBlock: #name ascending ]
Expand Down Expand Up @@ -117,5 +124,5 @@ SmallProjectRegistry >> projectsViewFor: aView [
priority: 5;
items: [ self projects ];
"send: #model;"
yourself.
actionUpdateButton
]

0 comments on commit 077e3ec

Please sign in to comment.