commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael A. Smith" <...@apache.org>
Subject Re: cvs commit: jakarta-commons/beanutils/src/test/org/apache/commons/beanutils DynaResultSetTestCase.java TestResultSet.java TestResultSetMetaData.java
Date Sat, 13 Jul 2002 01:46:44 GMT
On 12 Jul 2002 craigmcc@apache.org wrote:
[snip]
>   +<pre>
>   +  Connection conn = ...;
>   +  Statement stmt = conn.createStatement();
>   +  ResultSet rs = stmt.executeQuery
>   +    ("select account_id, name from customers");
>   +  ResultSetDynaClass rsdc = new ResultSetDynaClass(rs);
>   +  Iterator rows = (new ResultSetDynaClass(rs)).iterator();

shouldn't that be rsdc.iterator() rather than 
(new ResultSetDynaClass(rs)).iterator() ?

>   /**
>    * <p>Implementation of <code>DynaClass</code> for DynaBeans that
wrap the
>    * <code>java.sql.Row</code> objects of a <code>java.sql.ResultSet</code>.
>    * The normal usage pattern is something like:</p>
>    * <pre>
>    *   ResultSet rs = ...;
>    *   ResutSetDynaClass rsdc = new ResultSetDynaClass(rs);
>    *   Iterator rows = rsdc.iterator();

It's what you used here anyway...  :)


regards,
michael


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


Mime
View raw message