Node:Defining New Classes,
Next:Creating Instances,
Previous:Introductory Remarks,
Up:Reference Manual
3.2 Defining New Classes
[ *fixme* Somewhere in this manual there needs to be an introductory
discussion about GOOPS classes, generic functions and methods, covering
- how classes encapsulate related items of data in slots
- why it is that, unlike in C++ and Java, a class does not encapsulate the
methods that act upon the class (at least not in the C++/Java sense)
- how generic functions provide a more general solution that provides for
dispatch on all argument types, and avoids idiosyncracies like C++'s
friend classes
- how encapsulation in the sense of data- and code-hiding, or of
distinguishing interface from implementation, is treated in Guile as an
orthogonal concept to object orientation, and is the responsibility of
the module system.
Some of this is covered in the Tutorial chapter, in Generic functions and methods - perhaps the best solution would be to expand
the discussion there. ]