You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Knut Anders Hatlen (JIRA)" <ji...@apache.org> on 2011/03/21 01:39:06 UTC

[jira] [Commented] (DERBY-5143) Remove unnecessary copying of the map in getTypeMap()

    [ https://issues.apache.org/jira/browse/DERBY-5143?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13008991#comment-13008991 ] 

Knut Anders Hatlen commented on DERBY-5143:
-------------------------------------------

One unintended side effect from the copying is that the returned map is mutable when using the JDBC 4.0 driver, whereas it's immutable with the JDBC 3.0 driver.

> Remove unnecessary copying of the map in getTypeMap()
> -----------------------------------------------------
>
>                 Key: DERBY-5143
>                 URL: https://issues.apache.org/jira/browse/DERBY-5143
>             Project: Derby
>          Issue Type: Improvement
>          Components: JDBC
>    Affects Versions: 10.8.0.0
>            Reporter: Knut Anders Hatlen
>            Assignee: Knut Anders Hatlen
>            Priority: Minor
>
> The JDBC 4.0 Connection classes implement getTypeMap() by calling super.getTypeMap() and copying the resulting map. This is done to prevent an unchecked compiler warning that we would see if we simply returned super.getTypeMap() in this method. It would be cheaper and simpler to return super.getTypeMap() and ignore the warning.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira