This week's giveaway is in the Spring forum.
We're giving away four copies of REST with Spring (video course) and have Eugen Paraschiv on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes How to create a table Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "How to create a table" Watch "How to create a table" New topic

How to create a table

John Lincoln
Ranch Hand

Joined: Feb 11, 2003
Posts: 192
I want to create a table, which stores all the information.
For example if i have a class like
public class person {
public string name;
public int ssn;
public int age;
What i want to do is i want extract all the information from the object and store in the data structure like:
Name SSN Age
I want this data structure to be ordered.
can some one tell me , how to do this.
Please help .
Thanks for your time
Mark Herschberg

Joined: Dec 04, 2000
Posts: 6037
From your other comments, I assume that by "table" you really mean data structure, as opposed to a GUI table, like JTable.
I suggest you check out Java Collections, which has a wealth of data structures for this type of purpose.
I agree. Here's the link:
subject: How to create a table
jQuery in Action, 3rd edition