Status: Fixed
Owner: ----
Labels: Type-Defect Priority-Medium
New issue 741 by
[hidden email]: better code and comment
http://code.google.com/p/moose-technology/issues/detail?id=741MooseGroupRuntimeStorage>>at: uniqueName ifAbsent: exceptionBlock
| entity na |
na := uniqueName asSymbol.
"look first by name and if not found"
entity := byName at: na ifAbsent: [nil].
entity notNil ifTrue: [^entity].
"iterates over all the elements"
entity := self
detect: [:each | na == each mooseName asSymbol]
ifNone: exceptionBlock.
entity notNil ifTrue: [byName at: na put: entity].
^entity
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev