Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hashmap Vs DTO

 
Gillian Daniel
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have been sitting pondering for a day now, and I thought it was about time I asked for outside advice.
Is it better for me to implement a DTO/Model object for a record? I mean, I know what fields I have without looking in the db file, as they are stated in the question paper, so would it be wrong to use this information to create a DTO to transfer the record information?
Or should I take another approach, and use Hashmaps? Should I perhaps pretend that the only way I will know what fields are in the database is upon reading it?
Frankly, having written this, I now realise that nobody in their right mind would develop an application where the only way one would know what was in the database is by reading the header information, however I thought I would ask, incase this is slightly valuable?
Gillian
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic