Path: news.daimi.aau.dk!olm From: olm@daimi.aau.dk (Ole Lehrmann Madsen) Newsgroups: comp.lang.eiffel,comp.lang.beta Subject: Re: Java and Eiffel - Further comments: I am depressed. Date: 16 Apr 1997 14:42:21 GMT Organization: DAIMI, Computer Science Dept. at Aarhus University Lines: 78 Message-ID: <5j2ogd$3lp$1@gjallar.daimi.aau.dk> References: <5hel1s$afv@news-central.tiac.net> NNTP-Posting-Host: ariel.daimi.aau.dk X-Newsreader: NN version 6.5.1 (NOV) Xref: news.daimi.aau.dk comp.lang.eiffel:28608 comp.lang.beta:11038 In Chris.Bitmead@alcatel.com.au (Chris Bitmead uid(x22068)) writes: >jws@tiac.net (Jeffrey W. Stulin) writes: >> Inner Classes. Inner Classes are somewhat like method pointers, only with a >> typed class instead of a simple method. The painful details of this solution >> can be found at: >My understanding is that Inner classes are a kind of lambda calculus >as in Lisp lambda expressions. If this is so, then this is a great >addition to Java. (anything that makes a language more Lispish has got >to be good IMHO). I doubt that it is as simple to use a the lisp >version though. I agree that Inner classes are a great addition to Java. Inner classes are, however, not a new idea to object-oriented languages. Inner classes are the possibility to textually nest classes within classes: A: class method f1(); ... method f2(); ... B: class ... method g1(); ... method g2(); ... ... end; end; If X is an instance of A X: A then X.f1 and X.f2 are (as usual and as in Eiffel, C++, Java) are methods of the A-object referred by X. In the same way X.B is a local (or inner) class of the X-object. Simula had nested/inner classes, and this feature is also an important element of BETA. I think that most users of BETA consider nested/inner classes to be a very useful feature. Nested/inner classes may be considered an OO-generalization of block structure as found in Algol-60. If you are interested in more detailed information on OO and block-structure, check: O.L. Madsen, Block Structure and Object-Oriented Languages. In (B.D. Shriver, P. Wegner, eds.) Research Directions in Object-Oriented Programming. MIT Press, 1987. or Ole Lehrmann Madsen, Birger Moller-Pedersen, Kristen Nygaard: Object-oriented programming in the BETA programming language. Addison-Wesley, June 1993, ISBN 0 201 62430 3 ---olm *************** BETA information Sources *********************************** WWW: http://www.mjolner.dk http://www.daimi.aau.dk/~beta News: comp.lang.beta FAQ: http://www.daimi.aau.dk/~beta/FAQ E-mail: info@mjolner.dk Address: Mjolner Informatics, Science Park Aarhus, Gustav Wieds Vej 10, DK-8000, Aarhus C, DENMARK Tel.: +45 86 20 20 00 Fax.: +45 86 20 12 22 *****************************************************************************