WE WRITE CUSTOM ACADEMIC PAPERS

100% Original, Plagiarism Free, Tailored to your instructions

Order Now!

java part 2; Advanced Programming

java part 2; Advanced Programming
Introduction
You are required to implement a basic Java program using Java (SE 5.0 or later).
This assignment is designed to:
? Test your knowledge of basic Java concepts;
? Evaluate your ability to design programming logic;
? Practise simple object design in Java.
This is an individual assignment and worth 10% towards your final grade.
Academic Integrity
The submitted assignment must be your own work. No marks will be awarded for any parts which are not created by you.
Plagiarism is treated very seriously at RMIT. Plagiarism includes copying code directly from other students, internet or other resources without proper reference. Sometimes, students study and work on assignments together and submit similar files which may be regarded as plagiarism. Please note that you should always create your own assignment even if you have very similar ideas. Plagiarism-detection tools will be used for all submissions. Penalties may be applied in cases of plagiarism.
Note that we will be using automatic plagiarism detection software!
Task Specification
You are to implement a book purchasing system, called TechBooks. The system keeps a list of book titles that can be purchased, in both physical and ebook form.
? You have to keep track of how many copies of the physical books are available for each title. If the user tries to buy a (physical) book and there are no copies available, then the system outputs an error message.
? Some (not all) titles are available in ebook form. If the ebook exists for that title, then there is always a copy of the ebook available.
? All physical books cost $30.00; all ebooks cost $10.00. Prices may be updated in later versions.
? The user can request purchasing a book by giving the starting part of the title: the system then lists all books that start with that string, along with the number of copies and whether an ebook exists. The user enters which form of the book they want: if the book is available then it gets added to the user’s “shopping cart”.
o Matching for titles is not case-senstive.
? Once the user is finished selecting books, they “checkout and pay”; the system prints the final total price, and updates the number of copies of each book.
? The user has the option of viewing their shopping cart.
? The user has the option of printing the full list of books and their availability.
? The user can quit the system (before or after paying).
Part A (5%)
Implement the above specifications, without worrying about availability of physical books or whether there is an ebook. This means the only information you have to store about a book is the title. You do not have to use object oriented concepts at this point: you can implement the system in a main program as a single class. However, you should use multiple methods to break up the complexity of your code: i.e., don’t put it all in one method!
SIMPLIFICATIONS for Part A:
? when the user searches for a book, only the first match is displayed;
? in Part A you do not have to display or check for number of copies or ebook availability: just assume the book is available and a Physical book is selected (i.e. ignore ebooks);
? the Shopping Cart can only hold one book (any further selections replace it).
HINTS:
1. use an array of String to represent the list of books (i.e., just store the title);
2. String methods startsWith() and toUpperCase()/toLowerCase()may be useful.
The system should present a menu with the following options:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books in store
0. Quit
UPDATE: Option 1 only needs to display the FIRST matching title found and automatically adds it (a physical copy) to the Shopping Cart.
? If there are no matches then an error is printed.
Part B (4%)
The aim of Part B is to incorporate basic object oriented concepts into your program. In particular, define a Book class that contains all information related to a book: title, author, number of physical copies, and ebook availability. Your main program should be in a new Store class. Using the OO solution, your store could contain an array of Book objects.
Updates to the functionality:
? you now need to display and check for availability: i.e., check there are >0 books if the user requests a physical copy, or there is an ebook if the user requests that;
? when you print list of books, you list both title and author, as well as number of copies and ebook availability (see example below);
? your Shopping Cart should still be a single item (this is extended in Part C).
NOTE: it is OK to start using Object Oriented concepts from the start of the assignment if you prefer—i.e. it is not a requirement to complete Part A before introducing OO.
General Requirements
? Your programs should always perform basic input validation—e.g., you should check that selected options are not out-of-bounds.
? Programs must compile and run on CSIT machines (under Eclipse OR Linus servers.)
? Marks will be allocated for following good coding style, proper use of comments, consistent indentation, not “hard-coding” fixed values or assumptions, breaking up code appropriately into multiple methods, etc.
Book titles to include as data:
You must include the following titles as a minimum exactly as written below, for testing purposes (use only titles for testing Part A). Number of items in stock and ebook availability are indicated. For this assignment, you may hand-code these books directly into your Store:
? Absolute Java (Savitch) 5 yes
? JAVA: How to Program (Deitel and Deitel) 0 yes
? Computing Concepts with JAVA 3 Essentials (Horstman) 5 no
? Java Software Solutions (Lewis and Loftus) 5 no
? Java Program Design (Cohoon and Davidson) 1 yes
Sample interaction
Below is a sample interaction with the TechBooks system. You do not have to follow this precisely but it illustrates the required functionality. Text in bold is input from the user:
Welcome to TechBooks!
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 1
Enter title to search for: Java concepts
There is no title starting with that
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 1
Enter title to search for: Java
The following title is a match:
1. JAVA: How to program
0. cancel
What is your selection: 1
Do you want to buy this as an ebook: no
There are no physical copies of that book available!
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 1
Enter title to search for: Computing
The following title is a match:
1. Computing Concepts with JAVA 3 Essentials
0. cancel
What is your selection: 1
Do you want to buy this as an ebook: no
“Computing Concepts with JAVA 3 Essentials” has been added to your Cart
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 2
Your Shopping Cart contains the following items:
1. Computing Concepts with JAVA 3 Essentials
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 1
Enter title to search for: Absolute
The following title is a match:
1. Absolute Java
0. cancel
What is your selection: 1
Do you want to buy this as an ebook: no
“Absolute Java” has been added to your Cart
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 2
Your Shopping Cart contains the following items:
1. Absolute Java
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 3
You purchased the following item(s):
1. Absolute Java
You have purchased items to the total value of $30.00
Thanks for shopping with TechBooks!
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 4
The following titles are available:
1. Absolute Java (Savitch), 4 copies, no ebook
2. JAVA: How to Program (Deitel and Deitel), 0 copies, ebook available
3. Computing Concepts with JAVA 3 Essentials (Horstman), 5 copies, no ebook
4. Java Software Solutions (Lewis and Loftus), 5 copies, no ebook
5. Java Program Design (Cohoon and Davidson), 1 copy, ebook available
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 8
Sorry, that is an invalid option!
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 0
Goodbye!
Part C (1%) (this is tricky: don’t do this until after Part B)
Extend your solution so that:
? All matches to a search are displayed and the user selects using line number. An error is printed if the user selects an invalid line number, and the system prompts for a new line number. There should also be a “cancel” option.
? The Shopping Cart can hold up to at least 10 items. (There are no marks for it, but if you want to extend yourself, add a Remove Item from Shopping Cart option.)
To implement this extension, you need to use more arrays (for selection and Shopping Cart).
This extension would result in the following changes to the above interaction:
Choose an option:
1. Add a book to shopping cart
2. View shopping cart
3. Checkout
4. List all books
0. Quit
Please make a selection: 1
Enter title to search for: Java
The following title is a match:
1. JAVA: How to program — Deitel and Deitel
2. Java Software Solutions — Lewis and Loftus
3. Java Program Design — Cohoon and Davidson
0. cancel
Which number item do you wish to purchase: 1
Purchasing: JAVA: How to program
This is not available as an ebook
There is no ebook available for that title
“JAVA: How to program” has been added to your Cart
Submission Instructions and Marking
Submission will be via WebLearn and should be made by the advertised day and time. Full submission details will be provided via Blackboard. You are able to submit your assignment as many times as you like before the due date/time.
Submit all Java files.
? Submit only your FINAL submission (not separate Parts A/B/C)
? It is your responsibility to ensure your code compiles and runs on CS machines!!
? Include only *.java files; do not submit *.class files!
? Use zip/WinZIP to zip your files before submitting: do not submit rar or zipx files!!
Late submissions:
There will be a late submission period of 5 days for this assignment. Late submissions that are received before the end of the 5 day late submissions period will incur a late penalty of 10% per day (or part thereof), unless some prior arrangement has been made with the head tutor regarding an extension. Late penalty deductions will be applied to the marks awarded for the assignment, rather than the total marks available for the assignment. Submissions that are received after the late submission period expires may not be assessed and hence not receive any marks unless prior arrangements have been made for an extension.
All queries regarding this assignment should be directed to the Assignment 1 discussion forum on Blackboard.
 PLACE THIS ORDER OR A SIMILAR ORDER WITH US TODAY AND GET AN AMAZING DISCOUNT ?

Our Service Charter

  1. Excellent Quality / 100% Plagiarism-Free

    We employ a number of measures to ensure top quality essays. The papers go through a system of quality control prior to delivery. We run plagiarism checks on each paper to ensure that they will be 100% plagiarism-free. So, only clean copies hit customers’ emails. We also never resell the papers completed by our writers. So, once it is checked using a plagiarism checker, the paper will be unique. Speaking of the academic writing standards, we will stick to the assignment brief given by the customer and assign the perfect writer. By saying “the perfect writer” we mean the one having an academic degree in the customer’s study field and positive feedback from other customers.
  2. Free Revisions

    We keep the quality bar of all papers high. But in case you need some extra brilliance to the paper, here’s what to do. First of all, you can choose a top writer. It means that we will assign an expert with a degree in your subject. And secondly, you can rely on our editing services. Our editors will revise your papers, checking whether or not they comply with high standards of academic writing. In addition, editing entails adjusting content if it’s off the topic, adding more sources, refining the language style, and making sure the referencing style is followed.
  3. Confidentiality / 100% No Disclosure

    We make sure that clients’ personal data remains confidential and is not exploited for any purposes beyond those related to our services. We only ask you to provide us with the information that is required to produce the paper according to your writing needs. Please note that the payment info is protected as well. Feel free to refer to the support team for more information about our payment methods. The fact that you used our service is kept secret due to the advanced security standards. So, you can be sure that no one will find out that you got a paper from our writing service.
  4. Money Back Guarantee

    If the writer doesn’t address all the questions on your assignment brief or the delivered paper appears to be off the topic, you can ask for a refund. Or, if it is applicable, you can opt in for free revision within 14-30 days, depending on your paper’s length. The revision or refund request should be sent within 14 days after delivery. The customer gets 100% money-back in case they haven't downloaded the paper. All approved refunds will be returned to the customer’s credit card or Bonus Balance in a form of store credit. Take a note that we will send an extra compensation if the customers goes with a store credit.
  5. 24/7 Customer Support

    We have a support team working 24/7 ready to give your issue concerning the order their immediate attention. If you have any questions about the ordering process, communication with the writer, payment options, feel free to join live chat. Be sure to get a fast response. They can also give you the exact price quote, taking into account the timing, desired academic level of the paper, and the number of pages.

Excellent Quality
Zero Plagiarism
Expert Writers

Instant Quote

Subject:
Type:
Pages/Words:
Single spaced
approx 275 words per page
Urgency (Less urgent, less costly):
Level:
Currency:
Total Cost: NaN

Get 10% Off on your 1st order!