All Packages  Class Hierarchy  This Package  Previous  Next  Index  

Class CalculatorWithTimes

java.lang.Object
    |
    +----programming101.calculator.Calculator
            |
            +----.CalculatorWithTimes

public class CalculatorWithTimes
extends Calculator
Defines a simple graphic calculator consisting of a display region for accepting input and displaying results, and a number of buttons for various operations. The buttons respond "directly" when they are clicked. They receive a standard ActionEvent from the underlying windowing system. They also need information about the state of the calculator - among other things, the current cumulated value, the new value to be combined with the cumulated value, the last button clicked, etc., and this must be made accessible separately (in this case, through the constructors, or an accessor method). The only buttons supplied here are: ClearButton, EqButton, PlusButton, TimesButton.

Since:
15/03/98
Version:
1.3 (7/04/98)
Author:
© 1998 Peter T. Sander

Constructor Index

 o CalculatorWithTimes()
No-args constructor.

Constructors

 o CalculatorWithTimes
public CalculatorWithTimes()
No-args constructor. Sets up the various calculator GUI components.


All Packages  Class Hierarchy  This Package  Previous  Next  Index