Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa Java-Beginners RECYCLING SYSTEM IN JAVA WITH BLUEJ

Have Programming Question? Ask it here!
 
 
 


mikkel
RECYCLING SYSTEM IN JAVA WITH BLUEJ
0 Answer(s)      3 years and 8 months ago
Posted in : Java Beginners


Recycling System

The system, you are going to write, simulates a reverse vending machine. Such a machine is used to identify and collect used beverage containers for recycling or reuse from customers, who in return receive a monetary refund. When you use the system, you enter different cans and bottles into the machine, and when you are finished, you ?press a button? to get a refund ticket.

In the first iteration we assume that there are three different types of bottles or cans:

Deposit A: Cans and bottles less than 1 litre DKK 1,00

Deposit B: Exception. Bottles of plastics 0,5 litre DKK 1,50

Deposit C: Cans and bottles on or more than 1 litre DKK 3,00

The recycling machine has to be implemented in two classes: ReturnItem and ReturnMachine.

The cans and bottles are implemented in the class Container. Unless it is mentioned in the description below, you decide the names of the fields, parameters, variables and the methods, but it is important that the names you choose are appropriate.

The ReturnItem class should have the following characteristics:

Fields:

A character field storing the type of return item, e.g. ?A?, ?B? or ?C?

A character field storing a text describing the return item

An integer field storing the deposit value in ?Ýre?

An integer field storing the number of items returned for this type of item

Constructors:

A constructor having three parameters, initialising the two text fields and the deposit value field. The last field should also be initialised.

Accessor methods: Four different methods returning each of the fields

A method toString() that returns a String object as a concatenation of all the fields in a readable form

Mutator methods:

A method that increments the number of returned items when its type of return item is entered into the machine

A method setting the deposit value to the value passed as a parameter. The parameter value has to be checked, so it is positive and payable in coins (it has to be dividable by 50)

A method that resets this type of return item, e.g. the number of items returned is set to 0


Advertisement
View Answers

Related Tutorials/Questions & Answers:
RECYCLING SYSTEM IN JAVA WITH BLUEJ
RECYCLING SYSTEM IN JAVA WITH BLUEJ  Recycling System The system... is used to identify and collect used beverage containers for recycling or reuse from customers, who in return receive a monetary refund. When you use the system, you
Advertisements
Design a class named BankAccount to hold datas for a bank account in Java using Bluej Software - Java Interview Questions
Design a class named BankAccount to hold datas for a bank account in Java using Bluej Software  1)Design a class named BankAccount to hold the following data for a bank account: - Balance - Number of deposits
BlueJ (area of circle)
BlueJ (area of circle)  How does one write a program to calculate the area of a circle in BlueJ? Note that the user will have to provide the radius.   A simple program to calculate the area of a circle. radius provided
System Time
System Time  how do i store the system time in a variable in BlueJ
Java System class
Java System class  What is the purpose of the System class
what is the java cache system?
what is the java cache system?  To send the webapplication of java cache system
Pos System in Java
Pos System in Java  Where can I learn creating a POS system in java
JAVA SYSTEM LEVEL PROGRAMMING
JAVA SYSTEM LEVEL PROGRAMMING  Hi we all know how to create a file in our system. if we want to create a text file we can do this in this way, RIGHT... the file path immediately after creating a file in our system. After creating the file
mailing system in java - JavaMail
mailing system in java  i want to learn java mailing system can you help me out  Hi manglik, I am sending you a link. I hope that, following link will help you. Please visit for more information: http
Java get System Locale
Java get System Locale   ... are providing you an example which will obtain the locale of the system by using the System.getProperty(). This will provide all the properties of the system
system storage - Java Beginners
system storage  i want to know the systems current storage capacity.(i.e)total space available.total space occupied.total free space like in task manager using java program.can any one provide me a code for it.i need it only
fingerprint identification system on java
fingerprint identification system on java  sir i want full "fingerprint ateendance management" project on java please send me source code i am asking so many members but nobody send answer one of my friend suggest ask question
reservation system - Java Beginners
reservation system  hi help me write a program on a railway reservation system that records the destination of the passengers.It should be decided by the date on which they are to arrive on their destinations and also the number
Grading system - Java Beginners
Grading system  gud day...cn i ask for a javascript of a grading system text box input typed... that calculates quiz and assignment and a prelim + a quiz and assingment and a midterm + a quiz and assingment and a Semifinal
Java Hospital management system
Java Hospital management system  hospital management    <%@page contentType="text/html" pageEncoding="UTF-8"%> <%@page import="java.sql.*" %> <!DOCTYPE html> <html> <body>
Java project in online examination system
Java project in online examination system  how many and which tables are required at backend as SQL for online examination system project in jsp
Simple banking system using Java
Simple banking system using Java  I am trying to make a simple banking system that has only 3 interfaces which does not connect to the database... inheritance in java please help.Thank you
System
System  What is System in System.out.println() method? Is it a Class or a Package
railway reservation system - Java Beginners
railway reservation system  help me develop a code on a railway reservation system which maintains records of passengers traveling in the different trains on different dates reaching different destinations in the system
fingerprint attendance system - Java Beginners
fingerprint attendance system  i have project on attendance management system with a fingerprint scanner. i have my own interface but i have no experience how to begin.... please suggest me how to interface connect
dvd rental system - Java Beginners
dvd rental system  i am a young female who just got attracted by the java ptogramming and as i am now learning this, java is geting complecated evey day, now i looking for help with my java project. my project is about keeping
Cash Register System - Java Beginners
System for decision making is needed by the management of a newly opening ABC store. You are been given the task to design a system. The system starts when...(System.in); int menu = 0; System.out.println("School Registration System Main Menu
Java Project for College Admission System - Java Beginners
Java Project for College Admission System  I want Project for Student Information System in Java Back end-MS Access plz Give Me source code or website to download it. plz Help Me
Student Information System in Java - Java Beginners
Student Information System in Java  Hello Sir, I want Mini Java Project for Student Admission System.  Hi Friend, Can you provide us details regarding your project like student admission form, faculty information
i-election voting system project in java
i-election voting system project in java  I want source code and documentation project in java. send
online voting system source code in java
online voting system source code in java  Please send me source code for online voting system in java. please replay as fast as. Thank you
OutOfMemoryError Warning System - Java Tutorials
OutOfMemoryError Warning System 2004-07-20 The Java Specialists' Newsletter [Issue 092] - OutOfMemoryError Warning System Author: Dr. Heinz M. KabutzJDK... of The Java(tm) Specialists' Newsletter. Down here at the end of Africa, tech-toys
Project on mailing system using Java/JSP
Project on mailing system using Java/JSP  I am making a project on mailing system in Java/JSP. How could I display the inbox messages on the home page of user? Please tell me about how to handle these messages in database
Payroll and Leave management system in java web application
Payroll and Leave management system in java web application  Hi Can any one help me with leave management and payroll management system sample source...) as per now to me. And also let me know which technology in java for best fit
how to take system date in java servlet?????
how to take system date in java servlet?????  how to take system date in java servlet?????   Hi Friend, Try the following code: import java.io.*; import javax.servlet.*; import javax.servlet.http.*; public class
School Timetable System in java spring mvc 3
School Timetable System in java spring mvc 3  I want to do project in timetable generation for my project. but i dont know how generate. i'm using java spring Hibernate. please some one help me. Thanks thuva
Java example program to get the operating system's version
Java example program to get the operating system's version... check your current system's operating system version by the java code also... simple to know your operating system's version in java. This program displays
College Student Admission System Project in Java
College Student Admission System Project in Java   Front End -JAVA Back End - MS Access Hello Sir, I want College Student Admission Project in Java with Source code, that includes Following Forms 1) Student Admission based
Java Project for College Admission System - Java Beginners
Java Project for College Admission System  Hello Sir I urgently wants College Admission Project in Java,with Back End Microsft Access 2007 ,sir plz Give me Full Source Code.  Could u give me the filed should
Java Telephone directory management system
Java Telephone directory management system Here we are going to create a java application for Telephone directory system. For this, we have accepted ID, name... System"); System.out.println(); System.out.println("1. Accept Data
SMS alert system using Java - JSP-Servlet
SMS alert system using Java  Respected Sir/Mam, I need to develop an SMS alert application. Scope of the application: Basically... recipients. This can be developed using any kind of componentsThanks
SMS alert system in Java - JSP-Servlet
SMS alert system in Java  Hi, I have asked this questions 2 days before and awaiting answer. But i didn't get any replies so far?? Any experts please help me
Sales System.. Need Help!! - Java Beginners
Sales System.. Need Help!!  were going to make a sales system in our subject Database management and that will be our project, we already have a company to use. But the problem is.. our group dont know how to start, we dont have
Java get System Properties
Java get System Properties       In this section, you will learn how to obtain the system properties. The System class provides a Properties object that describes
Java example program to get the operating system name of the system
Java example program to get the operating system name of the system       java get Operating System name Many times we need to know the current operating system name on which we
Remote System OS name in JAVA - JSP-Servlet
Remote System OS name in JAVA  I need to print the different os names of the all computers in my local network. I know that with System.getProperty("os.name"), I get the os name of my computer but for the other computers, I have
i need attendce management system source code in java
i need attendce management system source code in java  i need attendance management system source code in java
how to browse the general files which are in system using java? - Java Beginners
how to browse the general files which are in system using java?  how to browse the general files which are in system using java? its just like in ms... java.  Hi friend, For browse and upload the file in jsp and visit
How to detect system failure using java code - Java Beginners
How to detect system failure using java code  I am doing a project... to detect the process that make failure. I have no idea about the project so please help me. And i need some site to download java source code
how to get an lan system ip and mac address in java code
how to get an lan system ip and mac address in java code  strong text
Java get System Locale
Java get System Locale     ... are providing you an example which will obtain the locale of the system by using the System.getProperty(). This will provide all the properties of the system
Product Register System using Java
Product Register System In this section, you will learn how to create product register system. For this, we have categorized the products by code 1 (food), 2  (water), 3 (magazine), 4 (stationery) and 5  (toys).  We have
Advertisements
 

 

 

DMCA.com