Commits


liyafan82 authored and Micah Kornfield committed d4d4a12ed02
ARROW-6334: [Java] Improve the dictionary builder API to return the position of the value in the dictionary This is an improvement of the addValue method. Previously, the method returns a boolean, indicating if the value has been successfully added to the dictionary. After the change, the method returns an integer, which is the position of the value in the dictionary. The purpose of this change: 1. the dictionary position contains more information, compared with a boolean indicating if the value is added successfully. 2. this information about the index in the dictionary can be useful, for example, to collect statistics about the dictionary. With the dictionary position, the information about if a value has been added can be easily determined. Closes #5177 from liyafan82/fly_0823_build and squashes the following commits: d45d0e99a <liyafan82> Improve the dictionary builder API to return the position of the value in the dictionary Authored-by: liyafan82 <fan_li_ya@foxmail.com> Signed-off-by: Micah Kornfield <emkornfield@gmail.com>