ihuzenko commented on a change in pull request #1854: DRILL-7373: Fix problems
involving reading from DICT type
URL: https://github.com/apache/drill/pull/1854#discussion_r324256231
##########
File path: exec/vector/src/main/codegen/templates/BaseReader.java
##########
@@ -83,6 +83,20 @@
*/
int find(int key);
+ /**
+ * Obtain the index for given key in current row used to find a
corresponding value with.
+ * Used in generated code when retrieving value from Dict using {@link
org.apache.drill.common.expression.PathSegment}
+ * with provided {@link
org.apache.drill.common.expression.PathSegment#getOriginalValue()}
+ * in cases when {@link
org.apache.drill.exec.vector.complex.DictVector#getValueType()} is complex.
+ *
+ * <p>The {@code key} is assumed to be of actual type, is not converted
and used as is.
+ *
+ * @param key key value
+ * @return index for the given key
+ * @see org.apache.drill.exec.vector.complex.DictVector
+ */
+ int find(Object key);
Review comment:
Are there further reasons to keep ```int find(String key);``` and ```void
read(String key, ValueHolder holder);``` methods in this interface after
adding methods with ```Object key``` ?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services