Question: How do I add lines of code to read all information from a file, put in an ArrayList, and display the ArrayList in its entirety

How do I add lines of code to read all information from a file, put in an ArrayList, and display the ArrayList in its entirety in a JTextArea? I got an answer but in my case I have more than one arraylist. I need to list all the ships,persons,and docks from my file. Ships, persons, and docks have their own arraylist. Therefore, how do I add lines of code to display each arraylist? My assignment is:

Project 2

Introduction - the SeaPort Project series

For this set of projects for the course, we wish to simulate some of the aspects of a number of Sea Ports.

Thanks.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!