12 Capstone 2
In lessons 8 - 11, I discussed how to access and use the Standard Java API, the difference between the String and StringBuilder class, static methods and variables, and finally the definition and uses of interfaces in Java.
This lesson is a capstone of these topics providing you with the opportunity to reinforce the skills learned. In this lesson, I will introduce a problem that is designed to include everything presented so far in the book.
This assignment involves creating an application for a book publishing company, ACME Publishing. ACME publishing offers both hardcopy and e-books. Here are the requirements for this assignment:
- Obtain the author information for the book including:
- author id, author name, address, email address, and phone number
- Allow the application to create book objects with the following information:
- author id, book title, number of pages
- When the user enters the book information, it can choose either ‘h’ for hard copy, ‘e’ for electronic copy, or ‘b’ for both
- Allow the user to enter the author and book information from the console as one line of String of data for each
- Print out the author and book information using a StringBuilder object