K, so I was being silly, what I actually wanted is sort of the emacs side of the communication. You know, the one Which sends out requests to evaluate clojure code (in this case lisp) instead of receiving the requests and sending The result back. I guess I could use swank-clojure and take out the parts I need.
-----Original Message----- From: clojure@googlegroups.com [mailto:cloj...@googlegroups.com] On Behalf Of Daniel Renfer Sent: Sunday, September 13, 2009 12:18 PM To: clojure@googlegroups.com Subject: Re: Using Clojure with Swank I'm not sure if this is exactly what you're looking for or not, but the swank-clojure package contains a (start-server) function that you can use to start a server inside a different application, then you can use M-x slime-connect to connect to that server. A while back I posted a paste that shows the function I use to set up my connection and guard against the server being reloaded if I re-evaluate that file. http://gist.github.com/126735 I don't understand why you need it written in java, however. I compile my swank checkout to a jar and then include it into my project. (using a dependency section in Maven) You could take your code to set up a connection and compile that to a class file (implementing whatever interfaces you need) and just call that from your java code. Hope this all helps. On Fri, Sep 11, 2009 at 6:46 PM, Gorsal <s...@tewebs.com> wrote: > > Hello ! > I need to rewrite a swank implementation which is in java for the Cusp > plugin. Looking around, I saw swank-clojure. I thought i would ask > more knowledgeable people than me whether it is what i'm looking for > (crosses fingers!). > > (1) The plugin currently starts a lisp implementation and loads swank > on it. It then causes it to create a port connection which connnects > to the java eclipse plugin. Then, to communicate/evaluate lisp, the > plugin sends things down the port connection like > (:emacs-rex (swank:connection-info) nil t 1) > and then the lisp swank port would return whatever. So, i guess what > i'm looking forward is some clojure implementation where i can simply > go (create-port ...) and then go (emaacs-rex connection ....) , etc. > to send down the port based on protocol. > > If so, is there any convenient tutorials or must i just find some code/ > doc and 'jump in?' > > Merci tres bien!<> > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---