Thanks for your suggestions!
I think decompiling and altering the class is probably a little bit
beyond my skill level. At first I tried to start a swank server from
my servlet, but that failed because GAE doesn't allow you to open
sockets. By decompiling and disabling that, I could probably
thank you for your clarifaction! I'll prepare the bundle then.
-Stefan
Rich Hickey richhic...@gmail.com writes:
On Tue, May 12, 2009 at 5:36 PM, Laurent PETIT laurent.pe...@gmail.com
wrote:
Hello,
It seems that it's really a matter of convention, I don't see any technical
problem of
Hi all,
Been discovering clojure, and I have a working slime up and running,
which is great.
One thing I have not managed to get working is the completion.
Actually, I have just discovered the problem, so I think I will share
it for anyone else this problem.
I have this set:
(setq
I gave a talk on Clojure at the St. Louis Java User Group last night.
You can find a description of the talk and the slides at
http://java.ociweb.com/javasig/knowledgebase/2009-05/index.html. See
the link at the bottom of the page. Feedback is welcomed!
--
R. Mark Volkmann
Object Computing,
On Fri, May 15, 2009 at 6:02 AM, Kees-Jochem Wehrmeijer
henc...@gmail.com wrote:
beyond my skill level. At first I tried to start a swank server from
my servlet, but that failed because GAE doesn't allow you to open
sockets. By decompiling and disabling that, I could probably work
This still
Hi everyone,
Trying to set up a new project using enclojure. I created the new project,
then put a new .clj file in Project Sources. In that file, I typed:
(defn main [] (print hi))
...which works in a REPL. But when I try to build the project, I get a big
old stack trace
Hi there,
I'm working on a project that involves transferring large files over
the network (100+MB) and wondering what would work better. I'm newer
to Java than I am to lisp, so I've just grabbed the most obvious
things from the API that I thought could possibly work:
(ns misc-ports
(:import
It looks like you're reading one byte at a time. Why not create a buffer and
read up to 1024 bytes at a time?
(defn write-file [ins outs]
(let [buffer (make-array Byte/TYPE 1024)]
(loop [len (.read ins buffer)]
(if (not (neg? len))
(do
(.write outs buffer 0 len)
(recur (.read ins
On May 15, 2009, at 11:10 AM, Christopher Wilson wrote:
But it turns out that this is rather slow. What would be some methods
to speed this up?
Consider using the new I/O API's in java.nio.*
From http://java.sun.com/j2se/1.5.0/docs/guide/nio :
The new I/O (NIO) APIs introduced in v 1.4
But it turns out that this is rather slow. What would be some methods
to speed this up?
You could also wrap your input and output stream's with
java.util.zip.GZIPInputStream and GZIPOutputStream to
compress/decompress the data either side. They allow you to specify
buffer sizes, so you could
On Sat, May 9, 2009 at 7:09 PM, aperotte apero...@gmail.com wrote:
It shouldn't be a problem to maintain immutability and also perform a
cross/cartesian product. I'm not sure I understand the problem.
It was a pretty bad example... what I meant was, in scientific computing,
people often have
I thumbed through the slideshow. I'm going to keep a copy on hand as
it's a very nice reference for things I tend to look up. The
collection summary was especially helpful. I didn't know about
efficiency considerations regarding inserting items into lists and
vectors, and I'll be making use of
A born Teacher!
Emeka
--~--~-~--~~~---~--~~
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
To unsubscribe from this group, send email to
Nice!
I had to learn a bit about jogl to get it to work - had to add -
Djava.library.path={path to my jogl lib directory} to my shell script.
The following is in model.clj:
(defn update [ref val]
(when (not (= @ref val)) (dosync (ref-set ref val
I believe this is not right: the deref
What are the use case scenarios where one is preferable to the other
in clojure ?
It looks to me like vectors almost completely overtake lists for all
purposes.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
I'm no expert, but I think this explain some:
Clojure's conj function is like Lisp's cons, but does the right
thing, depending on the data type. It is fast to add something to
the front of the list, and slower to add something to the end.
Vectors are the opposite, you can add to the end fast,
And here are some numbers from my machine:
(def my-list (list 'a 'b 'c 'd 'e 'f 'g 'h 'i 'j))
(def my-vector ['a 'b 'c 'd 'e 'f 'g 'h 'i 'j])
; ~44ms
(time (dotimes [x 100]
(conj my-list 'k)))
; ~26ms
(time (dotimes [x 100]
(pop my-list)))
; ~100ms
(time (dotimes [x 100]
(conj
On May 15, 2009, at 3:36 PM, Vagif Verdi wrote:
It looks to me like vectors almost completely overtake lists for all
purposes.
I think that's a fair statement.
Lists are still:
- key as the data structure that represents a call (to a function,
macro, or special form)
- useful for
I'm not a java security manager expert, but I've been playing with this a
bit.
Could you not do it the other way round? Start a REPL and run the server in
the REPL, instead of starting a server and trying to run a REPL in the
server?
I got as far as setting up the classpath and doing:
On May 14, 2009, at 7:54 PM, Stephen C. Gilardi wrote:
On May 14, 2009, at 7:13 PM, Ian Eure wrote:
I'm trying to process mid/large result sets with Clojure, and not
having any success.
(ns foo
(:require [clojure.contrib.sql :as sql]))
(def *db* {:classname com.mysql.jdbc.Driver
On May 15, 2009, at 6:14 PM, Ian Eure wrote:
I'm not having any luck at all. I tried visualvm, but it seems that
it doesn't support memory profiling unless you're running JDK 6. I
switched my default version (I'm on OS X here), and visualvm refuses
to start:
2009-05-15 14:03:15.495
I've been using clojure for a while at this point, and the approach
I've settled on launches clojure using -cp clojure.jar, and then my
user.clj file contains code that loads a bunch of thing into my
classpath.
After updating to r1369, which made some changes to classloaders that
I don't claim
the link at the bottom of the page. Feedback is welcomed!
Really excellent Mark!
--~--~-~--~~~---~--~~
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
To
23 matches
Mail list logo