Next: Code blocks (I), Previous: Creating classes, Up: Tutorial
This chapter continues from the previous chapter in demonstrating how one creates classes and subclasses in Smalltalk. In this chapter we will create two special subclasses of Account, known as Checking and Savings. We will continue to inherit the capabilities of Account, but will tailor the two kinds of objects to better manage particular kinds of accounts.
• The Savings class: | One of the two subclasses we’ll put together | |
• The Checking class: | And here is the other | |
• Writing checks: | Only in Smalltalk, of course |