Smalltalk is an
Object Oriented langauge based on
LISP and
Simula. This language was developed to be used on a device (called the Dynabook) that
Xerox was designing so that non-specialist
users could have a progamming language with the power of
LISP and the easy concept of
OO from Simula.
The first implementation of Smalltalk was completed in 1972 and went through many revisions until 1980 when Xerox decided to release it to the
public, even though at this stage the Dynabook project had been scrapped. A special issue of
Byte Magazine published some introductory articles and Xerox published 3 books (it was originally supposed to be 4) about smalltalk.
These books were (not the actual titles):
- The Blue book - describing the language and implementation
- The Orange book - describing Smalltalks UI
- The Green book - an aid to implementors (whatever that means)
Xerox looked for partners to help develop on other
platforms and
Apple Computers,
Digital Equipment,
Hewlett Packard and
Tektronix stepped forward. Problems were
weeded out and eventually, in 1983, the VI2 version was released.
Over the years, many more implementations have come and gone but the most notable ones around at the moment are; Squeak - a slightly smaller but very portable version being developed by some of the original designers of Smalltalk, and VisualWorks - a proprietry version for the Windows platform.
Smalltalk is a programming language that includes a whole development environment. Since this is an OO language, everything is refered to as an object, even down to the source and executable. This allows a great deal of flexibility because it means that the environment can be configured more easily to the tastes of the user.
The way Smalltalk carries out instructions is different from procedural languages such as C++ (once you get into Smalltalk, you'll know what I'm getting at). For example:
(1 + 2) printNl!
This prints out
3 as you'd expect but it does it differently from you would.
1 and
2 are actually
instances of the
integer class. Inside the brackets,
2 calls the
+ method in
1 whcih creates a new object,
3. The printNl method is then called from
3 which displays it on the screen.
To declare and object, simply type this:
Object
YourObject
YourOtherObject
Where
Object is the base class of everything in Smalltalk. You can use another class if you like though.
To create a new class, you need to send a message to the Object class.
You get the idea about what this language is about now?
As usual, /msg me with problems.
Bibliography:
http://kaka.cosc.canterbury.ac.nz/~wolfgang/cosc205/smalltalk1.html
http://www.cs.oswego.edu/~odendahl/manuals/smalltalk/tutorial/ - this tutorial appears to be very good!