I am using the Netbeans GUI builder to create a desktop Java application. I have a linked list that holds a bunch of objects. I was wondering if there was a way to create a JTable in the Netbeans GUI Builder and have it traverse through my linked list and write various fields of the objects at each node to rows in the table.
Obviously, there will be a variable amount of objects in the linked list, so I would also need a way to have this table dynamically adjust its size based on how many elements it is holding.
Lastly, I would like to be able to select a row in the table (Just one full row only. No multi-select. No only selecting one cell in the table etc.) and extract the data that is in the selected row.
Is there any way to do these things with a JTable in Netbeans? Or should I use a different Swing element for what I want to do? I am open for suggestions.
This is what my table looks like now -> https://i.stack.imgur.com/FWCKW.png There is lots of blank space that I need to get rid of, hence the dynamic part mentioned above.