Skip to content

Commit

Permalink
Added allElements method
Browse files Browse the repository at this point in the history
  • Loading branch information
JanBliznicenko committed Nov 21, 2023
1 parent 09be15f commit 1942565
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions repository/OpenPonk-Model/OPModelObject.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,14 @@ OPModelObject >> addedTo: anObject [
^ anObject
]

{ #category : #accessing }
OPModelObject >> allElements [
"should return all elements recursively (incl. sub-elements)"

^ self elements asSet flatCollect: [ :each |
(Set with: each) , each allElements ]
]

{ #category : #accessing }
OPModelObject >> belongsTo [
"FAMIX compatibility"
Expand Down

0 comments on commit 1942565

Please sign in to comment.