(I'm waking up in these minutes ) Another, perhaps better, way is to pass a custom type variable. This way has the advantage that you don't have to remember the Map keys, the editor will show you every data field.
Another, perhaps better, way is to pass a custom type variable. This way has the advantage that you don't have to remember the Map keys, the editor will show you every data field.
(I'm waking up in these minutes ) Another, perhaps better, way is to pass a custom type variable. This way has the advantage that you don't have to remember the Map keys, the editor will show you every data field.
It also has another advantage, compared to Maps: writing (hard-coding) string keys of a Map, as well as having to remember them (unless you create a nice module that simulates an Enum - I love Enums!) you risk typing them wrong; this cannot happen with a custom type.