You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Many SwingSet components use RowSetOps.getColumnText() and updateColumnText() which cast back and forth from java.sql.JDBCType (or java.sql.Types) to String. It would be preferable to eliminate unnecessary castings by storing component values in the appropriate Object type, using RowSet.updateObject() and RowSet.getObject().
The text was updated successfully, but these errors were encountered:
bpangburn
changed the title
Mimimize String casting between components and RowSet
Minimize String casting between SwingSet components and RowSet
Dec 11, 2020
getBoundColumnText() is used all over, this in turn uses getColumnText()
Not a trivial undertaking, but I think getObject() and updateObject() would be better for non-text components. I can be talked out of this and things are much cleaner than they were before with some consolidation in SSCommon and the cleanup done in SSRowSet. If we're doing something like storing a number in a text field then the casting is fine, but there are other places where it seems unnecessary to me.
Many SwingSet components use RowSetOps.getColumnText() and updateColumnText() which cast back and forth from java.sql.JDBCType (or java.sql.Types) to String. It would be preferable to eliminate unnecessary castings by storing component values in the appropriate Object type, using RowSet.updateObject() and RowSet.getObject().
The text was updated successfully, but these errors were encountered: