Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
Description
Looking at Scala/Kotlin data/case classes, it would be good to add additional helper methods to records. I am proposing (with suggestions from the mailing list):
- getAt(int i) which returns the i'th component
- toList() which returns the components as a List
- toMap() which returns the components as a Map
- components() which returns the components as a typed tuple (for records with up to currently 16 components)