[ https://issues.apache.org/jira/browse/CASSANDRA-11588?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15245228#comment-15245228 ]
Robert Stupp commented on CASSANDRA-11588: ------------------------------------------ TL;DR Although I think that the three methods getElementsType, getKeysType, getValuesType cause a bit more code, I'm in favor of leaving it as it is. For CASSANDRA-7826 it's probably sufficient to extend what CASSANDRA-7396 would provide plus CASSANDRA-11590. 7396 adds some code that deals with cells for collections - maybe this is what you're looking for. Technically simplified, a set in C* is a {{Map<SetElementsType, Void>}} and a list is a {{Map<TimeUUID, ListElementsType>}} - so would the getElementsType() return the value type of the C* "map" (the cell value type) or the "payload" type of the list/set? Don't get me wrong - but I think this could make it ambiguous. > Unify CollectionType#{getValuesType|getElementsType} > ---------------------------------------------------- > > Key: CASSANDRA-11588 > URL: https://issues.apache.org/jira/browse/CASSANDRA-11588 > Project: Cassandra > Issue Type: Improvement > Reporter: Alex Petrov > Assignee: Alex Petrov > Fix For: 3.x > > > Currently, {{ListType}} and {{SetType}} have {{getElementsType}}, while > {{MapType}} has {{getValuesType}} (along with {{getKeysType}}). > It might make sense to unify these types and make all three types have > {{getValuesType}}, which would simply mean renaming for {{Set}} and {{List}} > and pulling the method up to {{CollectionType}}. This would make > [#7826|https://issues.apache.org/jira/browse/CASSANDRA-7826] a bit simpler. -- This message was sent by Atlassian JIRA (v6.3.4#6332)