File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to pass entire row to another method for processing

 
Edmund Castermund
Ranch Hand
Posts: 99
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys,
was searching around and I did not come up with an answer for this q. Basically my situation is that I create a db search config via xml, and in the method where I process the result set, I do not know the data type (int, string, date, etc) or db column name of the data I am pulling. I have to get that info from an object structure I have built from the xml config.

So, in a case like so:




From the searching I have done I know that you want to keep the processing of a result set kind of in one place, but with my setup now I have some inner loops with duped code I'd like to avoid if possible.
thanks,
ec
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 33696
316
Eclipse IDE Java VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why not pass rs to processResultRow and have it call the proper getXXX methods?
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic