• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

stroing 3d table data data and displaying using struts logic

 
Ranch Hand
Posts: 110
Firefox Browser MySQL Database Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

I have some data and want to display in browser in table format using jsp and struts.

CITY1
DATE TIME1 TIME2 ..... TIMEN
DATE1 INT_DATA INT_DATA INT_DATA
DATE2 INT_DATA INT_DATA INT_DATA
....
...
DATEN INT_DATA INT_DATA INT_DATA

CITY2
DATE TIME1 TIME2 ..... TIMEN
DATE1 INT_DATA INT_DATA INT_DATA
DATE2 INT_DATA INT_DATA INT_DATA
....
...
DATEN INT_DATA INT_DATA INT_DATA

number of columns and rows are not fixed and can change each time

Which collection object is more suitable to store this data such that i can iterate the object to display the information using struts tags.
Any information on the logic will be really useful.

Thanks,
Sai
 
Sheriff
Posts: 22783
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm not that familiar with Struts, but a Map<List<X>> looks to be a good fit, with X being the object type for each row.
This map has the cities as keys, and the rows for each city inside the list for that city.
 
Die Fledermaus does not fear such a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic