Ella needs a CLI (Command Line Interface) program written in Java to maintain her contact list efficiently. Each of her contacts contains a name (full name), a phone number, and email, and an address. She’d like to be able to do the following functions.
The CLI should look like the one below. Note that Ella may accidentally enter an input that is not in the format that you expect, e.g. “ABC” instead of “2”. For any invalid inputs, the program must gracefully display an error message and let Ella re-enter again. The program only stops when she selects the function to quit. It must not stop or crash in any other circumstances. This fault-tolerance principle is applied to all program inputs.
Select a function (1-9):
The classes that are useful to you are File, Scanner, and PrintWriter. You can assume that the text file resides in the same directory with your program. The text file stores several contacts. Each contact is written in a line and has its fields separated by “;” like this example.
The contacts need to be in a text file.
John Smith; 0901234567; [email protected]; 120 Le Thanh Ton, D1, HCMC
Nguyen Minh Toan; 02837761300; [email protected]; 78 Le Van Sy, D3, HCMC
Bui Van Ba; 0913437582; [email protected]; 18 Nguyen Thi Thap, D7, HCMC
Ngo Hung; 0927654321; [email protected]; 89 Phan Dinh Phung, Ba Dinh, Ha Noi
Tran Tieu Vy; 0339997264; [email protected]; 5 Le Duan, Hai Chau, Da Nang
RMIT University Vietnam
Course: INTE2512 Object-Oriented Programming
Assessment: Assignment 1
Author: Your name (e.g. Nguyen Van Minh)
ID: Your student id (e.g. 1234567)
Created date: dd/mm/yyyy (e.g. 31/03/2019)
Last modified: dd/mm/yyyy (e.g. 05/04/2019)
Acknowledgment: If you use any resources, acknowledge here. Failure to do so will be considered as plagiarism.
DescriptionIn this final assignment, the students will demonstrate their ability to apply two ma
Path finding involves finding a path from A to B. Typically we want the path to have certain properties,such as being the shortest or to avoid going t
Develop a program to emulate a purchase transaction at a retail store. Thisprogram will have two classes, a LineItem class and a Transaction class. Th
1 Project 1 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
1 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