Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Implementing Custom CellRenderers

 
Alan Mc Kernan
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey there,

I'm adding custom cell renderers for most of the columns in the table.. For most columns it just changes the font and highlights available records but I change the text displayed on two columns

1. Available Date. My data file format is xx/xx/xxxx. I change this to a more readable example "Sat, 27 Jul 06"

2. For the Y/N column of smoking flag I change it to "Yes" or "No. Just to make it more clear to the reader.

I think these are obviously good things to do in the real world.. and were recommendations from several people I spoke to and told me "I dont really understand the dates very well and the text should look sharper, etc".

But would SUN fail me because im not fulfilling the requirments? I.e im not displaying the data exactly as its displayed in the data file?

Cheers for your thoughts,
Alan
 
Oricio Ocle
Ranch Hand
Posts: 284
Debian Firefox Browser Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But would SUN fail me because im not fulfilling the requirments? I.e im not displaying the data exactly as its displayed in the data file?

I am sure this is not a must in our assignments.
I think other way would have no sense

Regards
 
Gareth Llewellyn
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Personally, I feel they are never going to fail you for showing your mastery of JTable TableColumn objects and TableModels. I've made my smoking column a checkbox by overriding getColumnClass in my extension of AbstractTableModel, I think this only adds to the usability rather than increases my chance of failing.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic