Re: A way of passing functions as arguments in Java?






"yeldarb" <paulobrad@xxxxxxxxx> wrote in message
I'm aware that Java doesn't allow functions to be passed as arguments
but I was wondering if anyone had any ideas of code that could be
written to meet a similar aim for a package in Java.

Interface.
Our super big prime factorisation program works on numerical types which
implement the interface arithmetic, giving multiply, add, subtract, and
divide methods.

There is no need for function pointers.

--
www.personal.leeds.ac.uk/~bgy1mm
freeware games to download.


.



Relevant Pages

  • Re: Separate Compilation in Programming Languages
    ... within one package body. ... all, separate or otherwise. ... OK, so you like having textually separate spec and body, ... Clients of an interface do not depend ...
    (comp.lang.ada)
  • Re: Global variables
    ... I have a litte OT question: how do you initialize the Repository? ... first class triggered the Starter class. ... principle of object orientation is to design towards an interface, ... Starter class must not reside in the interface respository package. ...
    (comp.object)
  • Re: Looking for Java metrics article and tool
    ... The article was about a method of analyzing the 'oo-ness'/coupling of a java ... tool itself scored a 100%:) If I recall correctly, ... The article explained the opinion of the author that a package in Java ... should either completely be an 'interface' (consisting of only interfaces ...
    (comp.object)
  • Re: static or not?
    ... > Thus, for example, controller.Driver will register its Controller ... then I can strip away an interface from this ... and have it register that interface in the Registry. ... if this is done from class foo, what's foo's package? ...
    (comp.lang.java.help)
  • Looking for Java metrics article and tool
    ... The article was about a method of analyzing the 'oo-ness'/coupling of a java ... The article explained the opinion of the author that a package in Java ... should either completely be an 'interface' (consisting of only interfaces ... solve this was a staged initialization procedure. ...
    (comp.object)