commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dgra...@apache.org
Subject cvs commit: jakarta-commons/dbutils/src/java/org/apache/commons/dbutils/wrappers SqlNullCheckedResultSet.java
Date Wed, 05 Nov 2003 00:40:43 GMT
dgraham     2003/11/04 16:40:43

  Modified:    dbutils/src/java/org/apache/commons/dbutils
                        ProxyFactory.java
               dbutils/src/java/org/apache/commons/dbutils/wrappers
                        SqlNullCheckedResultSet.java
  Log:
  javadoc changes only.
  
  Revision  Changes    Path
  1.2       +4 -4      jakarta-commons/dbutils/src/java/org/apache/commons/dbutils/ProxyFactory.java
  
  Index: ProxyFactory.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/dbutils/src/java/org/apache/commons/dbutils/ProxyFactory.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ProxyFactory.java	2 Nov 2003 19:15:23 -0000	1.1
  +++ ProxyFactory.java	5 Nov 2003 00:40:43 -0000	1.2
  @@ -72,7 +72,7 @@
   import java.sql.Statement;
   
   /**
  - * Creates proxy implementations of JDBC classes.  This avoids 
  + * Creates proxy implementations of JDBC interfaces.  This avoids 
    * incompatibilities between the JDBC 2 and JDBC 3 interfaces.  This class is 
    * thread safe.
    * 
  
  
  
  1.2       +11 -9     jakarta-commons/dbutils/src/java/org/apache/commons/dbutils/wrappers/SqlNullCheckedResultSet.java
  
  Index: SqlNullCheckedResultSet.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/dbutils/src/java/org/apache/commons/dbutils/wrappers/SqlNullCheckedResultSet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SqlNullCheckedResultSet.java	2 Nov 2003 19:15:23 -0000	1.1
  +++ SqlNullCheckedResultSet.java	5 Nov 2003 00:40:43 -0000	1.2
  @@ -89,15 +89,17 @@
    * Usage example:
    * <blockquote>
    * <pre>
  - * Connection conn = getConnection(); // somehow get a connection
  + * Connection conn = // somehow get a connection
    * Statement stmt = conn.createStatement();
  - * ResultSet rs1 = stmt.executeQuery("SELECT col1, col2, FROM table1");
  + * ResultSet rs = stmt.executeQuery("SELECT col1, col2 FROM table1");
    * 
    * // Wrap the result set for SQL NULL checking
  - * SqlNullCheckedResultSet rs = new SqlNullCheckedResultSet(rs1);
  - * rs.setNullString("---N/A---"); // Set null string
  - * rs.setNullInt(-999); // Set null integer
  - * while(rs.next) {
  + * SqlNullCheckedResultSet wrapper = new SqlNullCheckedResultSet(rs);
  + * wrapper.setNullString("---N/A---"); // Set null string
  + * wrapper.setNullInt(-999); // Set null integer
  + * rs = ProxyFactory.instance().createResultSet(wrapper);
  + * 
  + * while (rs.next()) {
    *     // If col1 is SQL NULL, value returned will be "---N/A---"
    *     String col1 = rs.getString("col1");
    *     // If col2 is SQL NULL, value returned will be -999
  
  
  

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


Mime
View raw message