You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by bu...@apache.org on 2004/09/28 15:26:46 UTC

DO NOT REPLY [Bug 31446] - [dbutils] Proposal for a set of new ResultSetHandlers

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=31446>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31446

[dbutils] Proposal for a set of new ResultSetHandlers

dgraham@apache.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Proposal for a set of new   |[dbutils] Proposal for a set
                   |ResultSetHandlers.          |of new ResultSetHandlers



------- Additional Comments From dgraham@apache.org  2004-09-28 13:26 -------
I think the goal of these handlers is to be able to use a key to lookup the full
object in the returned Map.  So if you used the primary key column as the map
key you would be able to lookup the object in the map based on the primary key.

Rather than have a handler class for each type of object being stored in the map
it might be better to have one class with a protected method that generates the
object.  The default behavior could be to generate a Map for the row but users
could override that to generate a bean, arrray, etc.  Maybe the class could be
named KeyedHandler.

DbUtils' minimum Java version is 1.3 so LinkedHashMap can't be used in the
default implementation.  Again, we could provide a protected factory method that
users on 1.4 could override to return a LinkedHashMap.

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org