java.sql2 and primitive types
lance.andersen at oracle.com
Wed Oct 18 11:19:53 UTC 2017
> On Oct 18, 2017, at 4:33 AM, Lukas Eder <lukas.eder at gmail.com> wrote:
> I haven't seen any reference to primitive types in the suggested API, nor
> in the JavaOne 2017 CON1491 presentation. Have there been considerations of
> repeating API methods, e.g. in Result.ResultMap, such as:
> - byte getByte(String id)
> - short getShort(String id)
> - int getInt(String id)
> - long getLong(String id)
> - etc.
We have been trying to move away from specific get/setXXX as the API gets cluttered. I guess it is something that could be revisited if there is a significant performance difference
> Likewise, ParameterizedOperation could have setByte(), setShort(), etc.
> While I don't think this optimisation is significant in
> ParameterizedOperation, it could be worth thinking about in ResultMap, e.g.
> when someone fetches millions of longs vs millions of Longs.
> Whether driver implementations profit from this additional API would be
> entirely up to them.
<http://oracle.com/us/design/oracle-email-sig-198324.gif>Lance Andersen| Principal Member of Technical Staff | +1.781.442.2037
Oracle Java Engineering
1 Network Drive
Burlington, MA 01803
Lance.Andersen at oracle.com <mailto:Lance.Andersen at oracle.com>
More information about the jdbc-spec-discuss