Re: Best practices for java libraries

2012-12-10 Thread xavriley
You might like to checkout some of the videos from ClojureX recently. One was called 'playing nice with Java' and the other was a 10 min lightning talk by Rich Hickey on how they use Java in the Datomic project. I've only just joined the list so I don't want to get swept up in spam filters on

Re: Best practices for java libraries

2012-12-10 Thread Grant Rettke
Sounds like a good candidate for the Clojure documentation project. On Mon, Dec 10, 2012 at 5:33 PM, Mikera wrote: > Some thoughts from various Java libraries I have wrapped: > > - Normal functions are generally best for wrapping > - It can often make sense to have a protocol that d

Re: Best practices for java libraries

2012-12-10 Thread Mikera
Some thoughts from various Java libraries I have wrapped: - Normal functions are generally best for wrapping - It can often make sense to have a protocol that dispatched on the type of the Java object and/or clojure params for polymorphism and extension. Your public functions should often call

Best practices for java libraries

2012-12-10 Thread Michael Grubb
I've been searching for some best practices when it comes to wrapping existing Java libraries to make them more "clojurized." Unfortunately I've not found much. While I know enough to make something that works for me, I'd like to write it in such a manner that it can be

Using Java libraries inside of clojurescript on node.js

2012-07-27 Thread Sean Neilan
Hey All, I just wanted to point out the existence of this library called node-java. It lets you use java libraries on node.js and therefore you can use them within clojurescript! https://github.com/nearinfinity/node-java I have not tried it myself but I will soon. -Sean -- You received this

About wrapping Java libraries.

2010-06-10 Thread Nicolas Buduroi
Hi, I've been working on some Java libraries wrappers lately and came up with patterns on how to clojurize them. I'm wondering if you guys got other such patterns? Here's what I came up with: (import 'java.lang.reflect.Modifier) (defn clojurize-name [name] (appl

Blog post: Using Java libraries from Clojure

2009-09-06 Thread Michael Kohl
Hi all, after reading Charles Oliver Nutter's article "Scripting Java Libraries With JRuby" [1] I decided to "translate" his two example programs to Clojure. The result can be found on my blog: http://citizen428.net/archives/396-Using-Java-libraries-from-Clojure.html

Re: Newbie question on using Java Libraries

2009-08-04 Thread Adie
On Aug 3, 6:19 pm, Meikel Brandmeyer wrote: > Hi, > > On Aug 3, 10:16 am, Adie wrote: > > > for e.g > > (import '(javax.persistence Persistence) > > gives a > > java.lang.ClassNotFoundException: javax.persistence.Persistence > > (NO_SOURCE_FILE:0) error > > > How will i import javax.persistenc

Re: Newbie question on using Java Libraries

2009-08-03 Thread John Harrop
On Mon, Aug 3, 2009 at 4:16 AM, Adie wrote: > > Good Afternoon folks, > > I am a newbie to Clojure, coming from CL, with very little Java > background. > I am trying to use the 'javax.persistence' libraries, but i just cant > seem to import it properly > > for e.g > (import '(javax.persistence Pe

Re: Newbie question on using Java Libraries

2009-08-03 Thread Meikel Brandmeyer
Hi, On Aug 3, 10:16 am, Adie wrote: > for e.g > (import '(javax.persistence Persistence) > gives a > java.lang.ClassNotFoundException: javax.persistence.Persistence > (NO_SOURCE_FILE:0) error > > How will i import javax.persistence properly? You have to name the Classes or Interfaces in the `i

Newbie question on using Java Libraries

2009-08-03 Thread Adie
Good Afternoon folks, I am a newbie to Clojure, coming from CL, with very little Java background. I am trying to use the 'javax.persistence' libraries, but i just cant seem to import it properly for e.g (import '(javax.persistence Persistence) gives a java.lang.ClassNotFoundException: javax.pers

Re: Java libraries

2008-12-02 Thread Michael Wood
un.com/docs/books/tutorial/essential/concurrency/executors.html > >> So I assume you're expected to know >> and use Java libraries for this. For those of us who are coming to >> Clojure without knowing a whole lot of Java, it would be useful if >> someone could p

Re: Java libraries

2008-12-01 Thread Chouser
there are not idle threads available in its pool. If that abstracts away details you'd rather have your hand on, you may find this tutorial useful: http://java.sun.com/docs/books/tutorial/essential/concurrency/executors.html > So I assume you're expected to know > and use Jav

Java libraries

2008-12-01 Thread puzzler
Clojure is designed for concurrency, but I don't see any functions in the API to spin off new threads. So I assume you're expected to know and use Java libraries for this. For those of us who are coming to Clojure without knowing a whole lot of Java, it would be useful if someone cou