jameshartig commented on PR #1834:
URL:
https://github.com/apache/cassandra-gocql-driver/pull/1834#issuecomment-2641837825
I'd like to deprecate `SliceMap`, `MapScan`, `RowData`. The existing
`MapScan` is neat that it lets you pass in an existing map, but there's a call
out to always pass in a new map and it replaces the existing values with
non-pointers but accepts pointers. Seems a lot cleaner to just return a new map
with all of the values, and any null columns would be nil values in the map.
Something like `Values() (map[string]interface{}, bool)`. The name `Values`
lends itself to a `[]any` to match `Columns` so `ValuesMap` might be more
appropriate. I don't really like the `bool` but it could be confusing to return
empty map if there's no row. Either way you'd need to do `if ok` or `if
len(map) > 0`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]