Telephone is an interface type, so that it will be easy to
replace a non-GUI implementation of a telephone with a GUI implementation.
MailSystemTester launches the VMSS. Note the
telephone
variable, which is of interface type.
- Here, telephone refers to a TelephoneNoGUI
object. This object presents a console-based user interface.
- The telephone variable can easily be
made to reference a TelephoneFX object instead, which presents a
graphical user interface (GUI).
The
TelephoneNoGUI class extends the
Console class.
- Here, the handleInput method is overridden to send
telephone input to the Connection object.
- If handleInput were not overridden, it would default to
the implementation in the Console class, which simply
echoes the input to the display.
Use cases for the voice mail program can be divided into those carried
out by a caller and those carried out by the voice mailbox
owner.
The use cases for a voice mail caller are to
Reach An Extension
and to
Leave A Message.
Note how the second use case involves the first one.
The use cases for a voice mailbox owner are to
Log In and to
perform various menu actions.
Note that these use cases can come with
variations.
This section describes how use case walkthroughs can yield new
information for class descriptions using CRC cards.
This section describes UML diagrams that result from the voice mail
system design process.
Sequence diagrams are formal results of the use case walkthrough process.