[1954] in java-interest
Re: method/fn ptrs?
daemon@ATHENA.MIT.EDU (Arthur van Hoff)
Wed Sep 20 14:39:46 1995
From: Arthur.Vanhoff@Eng.Sun.COM (Arthur van Hoff)
To: daemon@java.Eng.Sun.COM (Frank Greco)
Date: Wed, 20 Sep 1995 09:02:29 -0800 (PDT)
Cc: java-interest@webrunner.neato.org (java)
In-Reply-To: <9509201426.AA27843@cfdev1.lehman.com> from "Frank Greco" at Sep 20, 95 10:26:05 am
Hi Frank,
> Ok... how does one do the equivalent of fn-ptrs in Java?
> I need to save an array of ptrs-to-methods, or whatever
> the equivalent is.... am I thinking C-ish too much here?
You can use interfaces to create the same effect.
However, Java does not treat code as a first class
object of the language so it is a little less powerful
then Lisp.
Have fun,
Arthur van Hoff (avh@eng.sun.com)
http://java.sun.com/people/avh/
Sun Microsystems Inc, M/S UPAL02-301,
100 Hamilton Avenue, Palo Alto CA 94301, USA
Tel: +1 415 473 7242, Fax: +1 415 473 7104
-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com