Use the SafeInput Library as needed to validate the user inputs; Block and Repeat until the user gets the input correct, do not terminate the script
Part 1: Writing to a text file: 1. Create a Person.java class to represent a Person Object. Person Fields String ID: String firstName: String lastName: String title: Mr. Mrs., Ms, Prol, Dr. Hon int YO; - Year of Birth - Range should be 1940-2010 - make sure validations hacen in the constructor as well as the setter method Methods Constructor Getters and Setters public String fullName) returns a concatenation of the first and last names public String for a Name) returns a concatenation of these and the full name public static int getAge(int year) - A static method that takes a year and returns an age - Use the Calendar ObjectRequires a bit of web search) public String to svatarecord) -returns a comma separated value osv) String suitable to writing to ajava text file - Make sure to use this function when saving data to the file. - e., 0001John Doe M. 2000 2. Create a program (Java main class called Personenerator.java a user will input the data to the console . a Person object is created for each entry Store all the person objects in an ArrayLister Export all the Person objects to a text file using the tocs Data Recordt method Grading The program runs with no errors The Person class includes all the fields and methods specified above Usage of the Calendar object to calculate age in the getAge method The program properly instantiates objects using the class constructor The program properly stores the objects in an ArrayList. Proper usage of Git and GitHub (frequent commits, explanatory commit messages Part 2: Person Reader: 1. Create a program (Java main class) called PersonReader.java Use the FileChooser to prompt the user to select the file you export in Part 1 Instantiate a Person Object for each record you read from the file Store all the Person Objects in an ArrayList Person Use the String.format or System.out.printf method to create any formed columnar display of the data ID Firstname Lastname Title YOB Doe 1990 2001 John 2002 Jane