KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > nqadmin > swingSet > SSTextDocument


1 /* $Id: SSTextDocument.java,v 1.23 2005/03/09 21:55:20 prasanth Exp $
2  *
3  * Tab Spacing = 4
4  *
5  * Copyright (c) 2003-2005, The Pangburn Company and Prasanth R. Pasala
6  * All rights reserved.
7  *
8  * Redistribution and use in source and binary forms, with or without
9  * modification, are permitted provided that the following conditions are met:
10  *
11  * Redistributions of source code must retain the above copyright notice, this
12  * list of conditions and the following disclaimer. Redistributions in binary
13  * form must reproduce the above copyright notice, this list of conditions and
14  * the following disclaimer in the documentation and/or other materials
15  * provided with the distribution. The names of its contributors may not be
16  * used to endorse or promote products derived from this software without
17  * specific prior written permission.
18  *
19  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
23  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29  * POSSIBILITY OF SUCH DAMAGE.
30  *
31  */

32
33 package com.nqadmin.swingSet;
34
35 import java.sql.*;
36 import java.io.*;
37 import java.text.*;
38 import javax.sql.*;
39 import javax.swing.text.*;
40 import javax.swing.event.*;
41 import java.util.GregorianCalendar JavaDoc;
42 import java.util.Calendar JavaDoc;
43 import java.util.StringTokenizer JavaDoc;
44 import com.nqadmin.swingSet.datasources.SSRowSet;
45
46 /**
47  * SSTextDocument.java
48  *<p>
49  * SwingSet - Open Toolkit For Making Swing Controls Database-Aware
50  *<p><pre>
51  * Java PlainDocument that is 'database-aware'. When developing a database
52  * application the SSTextDocument can be used in conjunction with the
53  * SSDataNavigator to allow for both editing and navigation of the rows in a
54  * database table.
55  *
56  * The SSTextDocument takes a SSRowSet and either a column index or a column name
57  * as arguments. Whenever the cursor is moved (e.g. navigation occurs on the
58  * SSDataNavigator), the document property of the bound Swing control changes to
59  * reflect the new value for the database column.
60  *
61  * Note that a SSRowSet insert doesn't implicitly modify the cursor which is why
62  * the SSDBNavImp is provided for clearing controls following an insert.
63  *</pre><p>
64  * @author $Author: prasanth $
65  * @version $Revision: 1.23 $
66  */

67 public class SSTextDocument extends javax.swing.text.PlainDocument JavaDoc {
68     
69     /**
70      * SSRowSet from which document will get/set values.
71      */

72     protected SSRowSet sSRowSet;
73
74     /**
75      * Name of SSRowSet column to which the document will be bound.
76      */

77     protected String JavaDoc columnName;
78     
79     /**
80      * Column SQL data type.
81      */

82     protected int columnType = -1;
83     
84     /**
85      * Index of SSRowSet column to which the document will be bound.
86      */

87     protected int columnIndex = -1;
88     
89     /**
90      * A straightforward implementation of MutableAttributeSet (a mutable
91      * collection of unique attributes) using a hash table.
92      */

93     protected SimpleAttributeSet attribute = new SimpleAttributeSet();
94
95     /**
96      * Underlying SSRowSet listener.
97      */

98     private final MyRowSetListener rowSetListener = new MyRowSetListener();
99     
100     /**
101      * Bound document listener.
102      */

103     private final MyDocumentListener documentListener = new MyDocumentListener();
104
105
106     /**
107      * Constructs a SSTextDocument with the given SSRowSet and column name.
108      * The document is bound to the specified column in the SSRowSet
109      *
110      * @param _sSRowSet SSRowSet upon which document will be based
111      * @param _columnName column name within SSRowSet upon which document will be based
112      */

113     public SSTextDocument(SSRowSet _sSRowSet, String JavaDoc _columnName) {
114         sSRowSet = _sSRowSet;
115         columnName = _columnName;
116         bind();
117     } // end public SSTextDocument(javax.sql.SSRowSet _sSRowSet, String _columnName) {
118

119     /**
120      * Constructs a SSTextDocument with the given SSRowSet and column index.
121      * The document is bound to the specified column in the SSRowSet.
122      *
123      * @param _sSRowSet SSRowSet upon which document will be based
124      * @param _columnIndex column index within SSRowSet upon which document will be based
125      */

126     public SSTextDocument(SSRowSet _sSRowSet, int _columnIndex) {
127         sSRowSet = _sSRowSet;
128         columnIndex = _columnIndex;
129         bind();
130     } // end public SSTextDocument(SSRowSet _sSRowSet, int _columnIndex) {
131

132     /**
133      * Sets the column name to which the document is to be bound.
134      *
135      * @param _columnName column Name to which the document is to be bound
136      */

137     public void setColumnName(String JavaDoc _columnName) {
138         columnName = _columnName;
139         columnIndex = -1;
140     }
141     
142     /**
143      * Returns the column name to which the document is bound.
144      *
145      * @return returns the column name to which the document is bound.
146      */

147     public String JavaDoc getColumnName() {
148         return columnName;
149     }
150
151     /**
152      * Sets the column index to which the document is to be bound.
153      *
154      * @param _columnIndex column index to which the document is to be bound
155      */

156     public void setColumnIndex(int _columnIndex) {
157         columnIndex = _columnIndex;
158         columnName = null;
159     }
160
161     /**
162      * Returns the index of the column to which the document is bound.
163      *
164      * @return returns the index of the column to which the document is bound
165      */

166     public int getColumnIndex() {
167         return columnIndex;
168     }
169     
170
171     /**
172      * Sets the SSRowSet to which the document is bound.
173      *
174      * @param _sSRowSet SSRowSet to which the component is bound
175      */

176     //public void setSSRowSet(SSRowSet _sSRowSet) throws SQLException {
177
public void setSSRowSet(SSRowSet _sSRowSet) {
178         sSRowSet = _sSRowSet;
179         bind();
180     } // end public void setSSRowSet(SSRowSet _sSRowSet) throws SQLException {
181

182     /**
183      * Returns the SSRowSet to which the document is bound.
184      *
185      * @return SSRowSet to which the document is bound
186      */

187     public SSRowSet getSSRowSet() {
188         return sSRowSet;
189     }
190
191     /**
192      * Retrieves meta data for column & initializes document text if applicable.
193      */

194     protected void bind() {
195
196         // CHECK FOR NULL COLUMN/ROWSET
197
if ((columnName==null && columnIndex==-1) || sSRowSet==null) {
198                 return;
199             }
200
201         // REMOVE LISTENERS TO PREVENT DUPLICATION
202
removeListeners();
203
204         // EXTRACT META DATA AND INITIALIZE DOCUMENT TEXT IF APPLICABLE
205
try {
206                 // IF COLUMN NAME ISN'T NULL, GET COLUMN INDEX - OTHERWISE, GET
207
// COLUMN NAME
208
if (columnName != null) {
209                         columnIndex = sSRowSet.getColumnIndex(columnName);
210                     } else {
211                         columnName = sSRowSet.getColumnName(columnIndex);
212                     }
213
214                 // GET COLUMN TYPE
215
columnType = sSRowSet.getColumnType(columnIndex);
216
217                 // IF ROWS PRESENT IN PRESENT SSROWSET THEN INITIALIZE THE DOCUMENT WITH THE TEXT
218
// GETROW RETURNS ZERO IF THERE ARE NO ROWS IN SSROWSET
219
if (sSRowSet.getRow() != 0) {
220                         String JavaDoc value = getText();
221                         insertString(0,value, attribute);
222                         insertUpdate( new AbstractDocument.DefaultDocumentEvent(0,getLength() , DocumentEvent.EventType.INSERT), attribute );
223                     }
224
225             } catch(SQLException se) {
226                 se.printStackTrace();
227             } catch(BadLocationException ble) {
228                 ble.printStackTrace();
229             }
230
231         // ADD BACK LISTENERS
232
addListeners();
233
234     } // end protected void bind() {
235

236     /**
237      * Method used by sSRowSet listeners to update the bound document.
238      */

239     protected void updateDocument() {
240             try {
241                 if ( sSRowSet.getRow() != 0 ) {
242                     String JavaDoc value = getText();
243                     if (value == null) {
244                         value = "";
245                     }
246                     replace(0, getLength(), value, null);
247                 } else {
248                     if ( getLength() > 0 ) {
249                         remove(0,getLength() );
250     // removeUpdate( new AbstractDocument.DefaultDocumentEvent(0,getLength() , DocumentEvent.EventType.REMOVE) );
251
}
252                 }
253             } catch(SQLException se) {
254                 se.printStackTrace();
255             } catch(BadLocationException ble) {
256                 ble.printStackTrace();
257             }
258
259     } // end protected void updateDocument() {
260

261     /**
262      * Method used by document listeners to update the underlying sSRowSet.
263      */

264     protected void updateText(String JavaDoc strValue) {
265     // THIS METHOD IS USED BY THE DOCUMENT LISTENERS WHEN EVER THE USER CHANGES THE TEXT IN
266
// THE DOCUMENT THE CHANGES ARE PROPOGATED TO THE BOUND SSROWSET.
267
// THE UPDATE ROW WILL NOT BE CALLED BY THIS.
268
//
269
// THIS FUNCTION UPDATES THE VALUE OF THE COLUM IN THE SSROWSET.
270
// FOR THIS LOOK AT THE DATA TYPE OF THE COLUMN AND THEN CALL THE
271
// APPROPIATE FUNCTION
272
try {
273             strValue.trim();
274 // System.out.println("Update Text:" + columnName);
275

276             switch(columnType) {
277                 // IF THE TEXT IS EMPTY THEN YOU HAVE TO INSERT A NULL
278
// THIS IS ESPECIALLY THE CASE IF THE DATA TYPE IS NOT TEXT.
279
// SO CHECK TO SEE IF THE GIVEN TEXT IS EMPTY IF SO AND NULL TO THE DATABASE
280

281                 case Types.INTEGER:
282                 case Types.SMALLINT:
283                 case Types.TINYINT:
284                     // IF TEXT IS EMPTY THEN UPDATE COLUMN TO NULL
285
if ( strValue.equals("") ) {
286                         sSRowSet.updateNull(columnName);
287                     } else {
288                         int intValue = Integer.parseInt(strValue);
289                         sSRowSet.updateInt(columnName, intValue);
290                     }
291                     break;
292
293                 case Types.BIGINT:
294                     // IF TEXT IS EMPTY THEN UPDATE COLUMN TO NULL
295
if ( strValue.equals("") ) {
296                         sSRowSet.updateNull(columnName);
297                     } else {
298                         long longValue = Long.parseLong(strValue);
299                         sSRowSet.updateLong(columnName, longValue);
300                     }
301                     break;
302
303                 case Types.FLOAT:
304                     // IF TEXT IS EMPTY THEN UPDATE COLUMN TO NULL
305
if ( strValue.equals("") ) {
306                         sSRowSet.updateNull(columnName);
307                     } else {
308                         float floatValue = Float.parseFloat(strValue);
309                         sSRowSet.updateFloat(columnName, floatValue);
310                     }
311                     break;
312
313                 case Types.DOUBLE:
314                 case Types.NUMERIC:
315                     // IF TEXT IS EMPTY THEN UPDATE COLUMN TO NULL
316
// System.out.println("ppr" + strValue + "ppr");
317
if ( strValue.equals("") ) {
318                         sSRowSet.updateNull(columnName);
319                     } else {
320                         double doubleValue = Double.parseDouble(strValue);
321                         sSRowSet.updateDouble(columnName, doubleValue);
322                     }
323                     break;
324
325                 case Types.BOOLEAN:
326                 case Types.BIT:
327                     if (strValue.equals("")) {
328                         sSRowSet.updateNull(columnName);
329                     } else {
330                         // CONVERT THE GIVEN STRING TO BOOLEAN TYPE
331
boolean boolValue = Boolean.valueOf(strValue).booleanValue();
332                         sSRowSet.updateBoolean(columnName, boolValue);
333                     }
334                     break;
335
336                 case Types.DATE:
337                 case Types.TIMESTAMP:
338                     // IF TEXT IS EMPTY THEN UPDATE COLUMN TO NULL
339
if ( strValue.equals("") ) {
340                         sSRowSet.updateNull(columnName);
341                     } else if (strValue.length() == 10) {
342     // System.out.println(strValue);
343
// Date dateValue = Date.valueOf(strValue);
344
sSRowSet.updateDate(columnName, getSQLDate(strValue));
345                     } else {
346                         // do nothing
347
}
348                     break;
349
350                 case Types.CHAR:
351                 case Types.VARCHAR:
352                 case Types.LONGVARCHAR:
353                     // SINCE THIS IS TEXT FILED WE CAN INSERT AN EMPTY STRING TO THE DATABASE
354
// System.out.println( columnName + " " + strValue);
355
sSRowSet.updateString(columnName, strValue);
356                     break;
357
358                 default:
359                     System.out.println("Unknown data type");
360             } // end switch
361

362         } catch(SQLException se) {
363             se.printStackTrace();
364 // System.out.println(se.getMessage());
365
} catch(NumberFormatException JavaDoc nfe) {
366 // System.out.println(nfe.getMessage());
367
}
368
369     } // end protected void updateText(String strValue) {
370

371     /**
372      * Method used by sSRowSet listeners to get the new text when the SSRowSet
373      * events are triggered.
374      */

375     protected String JavaDoc getText() {
376         String JavaDoc value = null;
377         try {
378             // BASED ON THE COLUMN DATA TYPE THE CORRESPONDING FUNCTION
379
// IS CALLED TO GET THE VALUE IN THE COLUMN
380
switch(columnType) {
381                 case Types.INTEGER:
382                 case Types.SMALLINT:
383                 case Types.TINYINT:
384                     value = String.valueOf(sSRowSet.getInt(columnName));
385                     break;
386
387                 case Types.BIGINT:
388                     value = String.valueOf(sSRowSet.getLong(columnName));
389                     break;
390
391                 case Types.FLOAT:
392                     value = String.valueOf(sSRowSet.getFloat(columnName));
393                     break;
394
395                 case Types.DOUBLE:
396                 case Types.NUMERIC:
397                     value = String.valueOf(sSRowSet.getDouble(columnName));
398                     break;
399
400                 case Types.BOOLEAN:
401                 case Types.BIT:
402                     value = String.valueOf(sSRowSet.getBoolean(columnName));
403                     break;
404
405                 case Types.DATE:
406                 case Types.TIMESTAMP:
407                     Date date = sSRowSet.getDate(columnName);
408                     if (date == null) {
409                         value = "";
410                     } else {
411                         GregorianCalendar JavaDoc calendar = new GregorianCalendar JavaDoc();
412                         calendar.setTime(date);
413                         value = "";
414                         if (calendar.get(Calendar.MONTH) + 1 < 10 ) {
415                             value = "0";
416                         }
417                         value = value + (calendar.get(Calendar.MONTH) + 1) + "/";
418
419                         if (calendar.get(Calendar.DAY_OF_MONTH) < 10) {
420                             value = value + "0";
421                         }
422                         value = value + calendar.get(Calendar.DAY_OF_MONTH) + "/";
423                         value = value + calendar.get(Calendar.YEAR);
424                         //value = String.valueOf(sSRowSet.getDate(columnName));
425
}
426                     break;
427
428                 case Types.CHAR:
429                 case Types.VARCHAR:
430                 case Types.LONGVARCHAR:
431                     String JavaDoc str = sSRowSet.getString(columnName);
432                     if (str == null) {
433                         value = "";
434                     } else {
435                         value = String.valueOf(str);
436                     }
437                     break;
438
439                 default:
440                     System.out.println(columnName + " : UNKNOWN DATA TYPE ");
441             } // end switch
442

443         } catch(SQLException se) {
444             se.printStackTrace();
445         }
446               
447         return value;
448
449     } // end protected String getText() {
450

451     /**
452      * Converts a date string in "MM/dd/yyyy" format to an SQL Date.
453      *
454      * @param _strDate date string in "MM/dd/yyyy" format
455      *
456      * @return return SQL date for the string specified
457      */

458     protected Date getSQLDate(String JavaDoc _strDate) {
459         StringTokenizer JavaDoc strtok = new StringTokenizer JavaDoc(_strDate,"/",false);
460         String JavaDoc month = strtok.nextToken();
461         String JavaDoc day = strtok.nextToken();
462         String JavaDoc newStrDate = strtok.nextToken() + "-" + month + "-" + day;
463         return Date.valueOf(newStrDate);
464     }
465
466     /**
467      * Adds listeners for component and bound text field (where applicable).
468      */

469     private void addListeners() {
470         sSRowSet.addRowSetListener(rowSetListener);
471         addDocumentListener(documentListener);
472     }
473
474     /**
475      * Removes listeners for component and bound text field (where applicable).
476      */

477     private void removeListeners() {
478         sSRowSet.removeRowSetListener(rowSetListener);
479         removeDocumentListener(documentListener);
480     }
481
482     /**
483      * Listener(s) for the bound document used to update the underlying SSRowSet.
484      */

485     private class MyDocumentListener implements DocumentListener, Serializable {
486         // WHEN EVER THERE IS ANY CHANGE IN THE DOCUMENT CAN BE REMOVE UPDATE
487
// CHANGED UPDATE OR INSERT UPDATE GET THE TEXT IN THE DOCUMENT
488
// AND UPDATE THE COLUMN IN THE SSROWSET
489
// TO AVOID THE TRIGGERING OF UPDATE ON THE SSROWSET AS A RESULT OF UPDATING THE COLUMN VALUE
490
// IN SSROWSET FIRST REMOVE THE LISTENER ON SSROWSET THEN MAKE THE CHANGES TO THE COLUMN VALUE.
491
// AFTER THE CHANGES ARE MADE ADD BACK THE LISTENER TO SSROWSET.
492
public void removeUpdate(DocumentEvent de) {
493             sSRowSet.removeRowSetListener(rowSetListener);
494
495             try {
496             // System.out.println("remove update" + getText(0,getLength()) );
497
updateText(getText(0,getLength()));
498             } catch(BadLocationException ble) {
499                 ble.printStackTrace();
500             }
501             sSRowSet.addRowSetListener(rowSetListener);
502         }
503
504         public void changedUpdate(DocumentEvent de) {
505         // System.out.println("changed update");
506
}
507
508         // WHEN EVER THERE IS ANY CHANGE IN THE DOCUMENT CAN BE REMOVE UPDATE
509
// CHANGED UPDATE OR INSERT UPDATE GET THE TEXT IN THE DOCUMENT
510
// AND UPDATE THE COLUMN IN THE SSROWSET
511
public void insertUpdate(DocumentEvent de) {
512
513             sSRowSet.removeRowSetListener(rowSetListener);
514             try {
515             // System.out.println("insert update" + getText(0,getLength()));
516
updateText(getText( 0,getLength() ) );
517             } catch(BadLocationException ble) {
518                 ble.printStackTrace();
519             }
520             sSRowSet.addRowSetListener(rowSetListener);
521         }
522
523     } // end private class MyDocumentListener implements DocumentListener, Serializable {
524

525
526     /**
527      * Listener(s) for the underlying SSRowSet used to update the bound document.
528      */

529     private class MyRowSetListener implements RowSetListener, Serializable {
530         // WHEN EVER THERE IS A CHANGE IN SSROWSET CAN BE ROW-CHANGED OR SSROWSET-CHANGED
531
// OR CURSOR-MOVED GET THE NEW TEXT CORRESPONDING TO THE COLUMN AND UPDATE THE DOCUMENT
532
// WHILE DOING SO YOU CAN CAUSE A EVENT TO FIRE WHEN DOCUMENT CHANGES SO REMOVE THE
533
// LISTENER ON THE DOCUMENT THEN CHANGE THE DOCUMENT AND THEN ADD BACK THE LISTENER
534
public void cursorMoved(RowSetEvent event) {
535             removeDocumentListener(documentListener);
536 // System.out.println("Cursor Moved");
537
updateDocument();
538
539             addDocumentListener(documentListener);
540         }
541
542         // WHEN EVER THERE IS A CHANGE IN SSROWSET CAN BE ROW-CHANGED OR SSROWSET-CHANGED
543
// OR CURSOR-MOVED GET THE NEW TEXT CORRESPONDING TO THE COLUMN AND UPDATE THE DOCUMENT
544
// WHILE DOING SO YOU CAN CAUSE A EVENT TO FIRE WHEN DOCUMENT CHANGES SO REMOVE THE
545
// LISTENER ON THE DOCUMENT THEN CHANGE THE DOCUMENT AND THEN ADD BACK THE LISTENER
546
public void rowChanged(RowSetEvent event) {
547             removeDocumentListener(documentListener);
548 // System.out.println("Row Changed");
549
updateDocument();
550
551             addDocumentListener(documentListener);
552         }
553
554         // WHEN EVER THERE IS A CHANGE IN SSROWSET CAN BE ROW-CHANGED OR SSROWSET-CHANGED
555
// OR CURSOR-MOVED GET THE NEW TEXT CORRESPONDING TO THE COLUMN AND UPDATE THE DOCUMENT
556
// WHILE DOING SO YOU CAN CAUSE A EVENT TO FIRE WHEN DOCUMENT CHANGES SO REMOVE THE
557
// LISTENER ON THE DOCUMENT THEN CHANGE THE DOCUMENT AND THEN ADD BACK THE LISTENER
558
public void rowSetChanged(RowSetEvent event) {
559             removeDocumentListener(documentListener);
560 // System.out.println("RowSet Changed");
561
updateDocument();
562
563             addDocumentListener(documentListener);
564         }
565
566     } // end private class MyRowSetListener implements RowSetListener, Serializable {
567

568 } // end public class SSTextDocument extends javax.swing.text.PlainDocument {
569

570
571
572 /*
573  * $Log: SSTextDocument.java,v $
574  * Revision 1.23 2005/03/09 21:55:20 prasanth
575  * Added TIMESTAMP column type in updateText & getText functions.
576  *
577  * Revision 1.22 2005/02/10 20:13:03 yoda2
578  * Setter/getter cleanup & method reordering for consistency.
579  *
580  * Revision 1.21 2005/02/09 22:42:34 yoda2
581  * JavaDoc cleanup.
582  *
583  * Revision 1.20 2005/02/07 20:36:41 yoda2
584  * Made private listener data members final.
585  *
586  * Revision 1.19 2005/02/05 18:16:20 yoda2
587  * API cleanup.
588  *
589  * Revision 1.18 2005/02/04 23:05:10 yoda2
590  * no message
591  *
592  * Revision 1.17 2005/02/04 22:48:54 yoda2
593  * API cleanup & updated Copyright info.
594  *
595  * Revision 1.16 2004/11/11 14:45:33 yoda2
596  * Using TextPad, converted all tabs to "soft" tabs comprised of four actual spaces.
597  *
598  * Revision 1.15 2004/11/10 22:55:51 dags
599  * Modified boolean support, as a side efect of SSDBCheckBox update.
600  *
601  * Revision 1.14 2004/11/01 15:53:30 yoda2
602  * Fixed various JavaDoc errors.
603  *
604  * Revision 1.13 2004/11/01 15:48:39 yoda2
605  * Added support for NUMERIC. Made type support consistent across SwingSet: INTEGER, SMALLINT, TINYINT (Integer); BIGINT (Long); FLOAT (Float); DOUBLE, NUMERIC (Double); BOOLEAN, BIT (Boolean); DATE (Date); CHAR, VARCHAR, LONGVARCHAR (String).
606  *
607  * Revision 1.12 2004/10/25 22:13:43 yoda2
608  * Updated JavaDoc for new datasource abstraction layer in 0.9.0 release.
609  *
610  * Revision 1.11 2004/10/25 19:51:03 prasanth
611  * Modified to use the new SSRowSet instead of RowSet.
612  *
613  * Revision 1.10 2004/10/22 16:27:24 prasanth
614  * Added CHAR types to the list of supported data types.
615  *
616  * Revision 1.9 2004/08/11 15:59:49 prasanth
617  * Removed check for \r' in one of the constructors.
618  *
619  * Revision 1.8 2004/08/10 22:06:59 yoda2
620  * Added/edited JavaDoc, made code layout more uniform across classes, made various small coding improvements suggested by PMD.
621  *
622  * Revision 1.7 2004/08/02 15:47:14 prasanth
623  * 1. Added setColumnName, setColumnIndex, and setRowSet functions.
624  * 2. Added getColumnName, getColumnIndex, and getRowSet functions.
625  * 3. Added init method.
626  *
627  * Revision 1.6 2004/03/08 16:43:37 prasanth
628  * Updated copy right year.
629  *
630  * Revision 1.5 2004/01/27 19:09:22 prasanth
631  * In the RowSet Listener replaces remove and insert functions with
632  * replace function.
633  *
634  * Revision 1.4 2003/11/26 21:31:51 prasanth
635  * Calling performCancelOps().
636  *
637  * Revision 1.3 2003/10/31 16:08:46 prasanth
638  * Added method getSQLDate().
639  * Corrected a bug.( when a text field is linked to a date column, the column
640  * should not be updated until the user enters the complete date.)
641  * The text document waits till a 10 char date is entered.
642  *
643  * Revision 1.2 2003/09/25 14:27:45 yoda2
644  * Removed unused Import statements and added preformatting tags to JavaDoc descriptions.
645  *
646  * Revision 1.1.1.1 2003/09/25 13:56:43 yoda2
647  * Initial CVS import for SwingSet.
648  *
649  */
Popular Tags