swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Making swarm use functions from other toolkits (Glib, GNUstep)


From: Alex Lancaster
Subject: Re: Making swarm use functions from other toolkits (Glib, GNUstep)
Date: 22 Sep 1999 14:31:09 -0600
User-agent: Gnus/5.070095 (Pterodactyl Gnus v0.95) Emacs/20.4

>>>>> "PJ" == Paul Johnson <address@hidden> writes:

[...]

PJ> That reminds me to ask.  Irene's announcement of Swarm 2 said that
PJ> a single app can have some Java classes and some Obj-c classes.
PJ> If I were to use the Java collection's list library in the Java
PJ> files, could that list be then passed over to the Obj-C class?
PJ> would it know what to do with it?

I assume you are referring to this:

>>>>> "IL" == Irene Lee <address@hidden> writes:

IL> The primary feature of Swarm 2.0 is support for the Java programming
IL> language.  Swarm models may now be implemented using Objective C,
IL> Java, or both.

Well, `both' actually is a little ambiguous in this context, I don't
think Irene was suggesting implementing your model with Java classes
and Objective C classes in the same model, but rather in that you
could do both "in parallel" (i.e. heatbugs and jheatbugs).  

Unfortunately, there's no magic in Swarm (or elsewhere, for that
matter) that would suddenly allow Objective C objects to have
knowledge of Java objects that the user didn't provide (i.e. you'd
need to do some lower-level stuff to make this work).

It's technically possible to export the Objective C interface of a
class to Java (via the same or similar technique to that which we use
in Swarm: parsing the header files and generating stubs for JNI), but
there's no `automagic' way of writing an Objective C class and a Java
class, and ensuring that they can interoperate without the user
providing a significant number of clues.

GCC is in the process of integrating link-level support with Java,
which might allow this kind of coexistence, but that's not tested in
the Swarm context as yet.  Furthermore, at some stage we may split out
the protocol parsing stuff from Swarm, and make it generic enough so
that it could handle third-party libraries, but again that's further
down the track.

For the bulk of users, who'd rather not invest time with learning JNI
(Java Native Interface) features I'd suggest spending time on
implementing your model in either Java or Objective C, but not both
`simultaneously' as it were.

 --- Alex

-- 
  Alex Lancaster           |  e-mail: address@hidden
  Swarm Program            |     web: http://www.santafe.edu/~alex
  Santa Fe Institute       |     tel: +1-(505) 984-8800 (ext 242)
-------------------------------------------------------------------

                  ==================================
   Swarm-Support is for discussion of the technical details of the day
   to day usage of Swarm.  For list administration needs (esp.
   [un]subscribing), please send a message to <address@hidden>
   with "help" in the body of the message.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]