Re: clojure gen-class questions

2010-02-09 Thread Brian Wolf
Hi, I also am confused about gen-class, looking for a pointer to some code examples. Thanks, Brian ??? wrote: Oh...So to make methods I must declare them in gen-class clause and if some function wasn't include in gen-class clause, it wouldn't be a method even if it had a prefix fr

Re: clojure gen-class questions

2010-02-10 Thread Brian Wolf
yes,thank you, this looks very helpful On Feb 9, 3:44 pm, Meikel Brandmeyer wrote: > Hi, > > I wrote up a post:http://tr.im/NwCL > > Hope it helps. > > Sincerely > Meikel -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send em

Re: clojure gen-class questions

2010-02-10 Thread Brian Wolf
Meikel, As a beginner, I tried running the first example,changing namespaces or not, etc ,and I keep getting user=> (ns some.Example (gen-class)) nil some.Example=> (defn -toString [this] "HI !") #'some.Example/-toString some.Example=> (ns user) nil

newbie question re-seq

2010-02-12 Thread Brian Wolf
Hi, This is from the book: (re-seq \w+ "the quick brown fox") -> ("the" "quick" "brown" "fox") But when I try it, these don't work: user> (re-seq \w+ "the quick brown fox") ; Evaluation aborted. clojure.lang.LispReader$ReaderException: java.lang.Exception: Unsupported character: \w+ (NO_SOU

Re: newbie question re-seq

2010-02-12 Thread Brian Wolf
Thanks, I wonder why the book doesn't use that? Michał Marczyk wrote: Replace \w+ with #"\w+". (#"..." is the regex literal syntax.) Sincerely, Michał -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clo

leiningen powershell script

2010-02-14 Thread Brian Wolf
Hi, I am trying to run( http://bit.ly/82zo95 ) powershell script for leiningen install under windows, but it says it can't find file, which file it doesn't say. I was wondering what dependencies leiningen has? Do I need maven pre- installed (I don't see anything

Re: leiningen powershell script

2010-02-15 Thread Brian Wolf
Rob Wolfe wrote: On 15 Lut, 07:42, Brian Wolf wrote: Hi, I am trying to run(http://bit.ly/82zo95<http://bit.ly/82zo95> ) powershell script for leiningen install under windows, but it says it can't find file, which file it doesn't say. I was wondering what depend

Re: leiningen powershell script

2010-02-15 Thread Brian Wolf
Rob Wolfe wrote: On 15 Lut, 20:50, Brian Wolf wrote: Rob Wolfe wrote: On 15 Lut, 07:42, Brian Wolf wrote: Hi, I am trying to run(http://bit.ly/82zo95<http://bit.ly/82zo95> ) powershell script for leiningen install under windows, but it says it can'

#clojure irc

2010-02-16 Thread Brian Wolf
Hi, I was wondering if irc #clojure is open to anyone and if it is, what is the protocol? I get cannot send to channel error. I'm not familiar with irc. Thanks Brian -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send

Re: Clojure box

2010-02-18 Thread Brian Wolf
Zeynel wrote: Hello, I am totally new to Clojure. Do you recommend using Clojure Box for windows installation? I am not an expert user or programmer. Thank you. I use it all the time. And its a gentle introduction to emacs Brian -- You received this message because you are subscribed to

noobie library load

2010-02-18 Thread Brian Wolf
Hi, I have a self contained library let me call it "http_example.jar" (i assume the name of the jar file is irrelevant) and contains this is the root resource: com.example.clojure.http__init.class (I know its there) The file, "http_example.jar", to the best I can tell sits squarely in my cl

compojure stop server?

2010-02-19 Thread Brian Wolf
Hi, Is there something like a (stop-server) I don't see anything here http://compojure.org/docs thanks Brian -- 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 memb

Re: Major changes in ClojureX

2010-02-21 Thread Brian Wolf
Michael Kohl wrote: I hope these mails don't annoy people, but from mails and Twitter I know that quite a few people actually seem to be using ClojureX, so I also wanted to post the information here: http://citizen428.net/archives/415-Major-changes-in-ClojureX.html Cheers, Michael Hi, I t

noob: call multimethod in a map?

2010-04-16 Thread Brian Wolf
Hi, Is it possible to call a multimethod in a map? In this simplified example, I just want to increment every element of the array when the multimethod is called (my real application is operating on sets of hash tables ie database ) (defmulti cc (fn [c v] [(:category c) ])) (defmethod cc [:toys

Re: noob: call multimethod in a map?

2010-04-16 Thread Brian Wolf
ok, I tested it, it works thanks Brian -- 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 unsubscri

how to develop patches to libraries

2010-05-12 Thread Brian Wolf
Hi, Whats the idiomatic or best method to develop patches to pre-exisitng libraries using clojars, do I git the source to my computer, put put [lein-clojars "0.5.0"] in project file, obviously renaming the project, and do I take original dependenicies out, or leave in, or am I on the wrong track?

how do I clojurize this java ?

2010-05-16 Thread Brian Wolf
Hi, I was wondering how to 'clojurize' twitterStream = new TwitterStreamFactory().getInstance(args[0], args[1]); from the java code below,which is the from the open source twitter4j java library ( http://twitter4j.org/en/index.html ) from the source, .getInstance(args[0], args[1]) is a "pro

Re: how do I clojurize this java ?

2010-05-17 Thread Brian Wolf
tory > user=> (.getInstance (TwitterStreamFactory.) "foo" "bar") > [Sun May 16 17:09:37 PDT 2010]Using class > twitter4j.internal.logging.StdOutLoggerFactory as logging factory. > # password='**''}}> > > On May 16, 1:25 pm, Brian Wolf wro

noob : congomongo to disk

2010-06-05 Thread Brian Wolf
Hi, I would like to save a mongo collection to a file, and later read that file into a clojure program. congomongo 'fetch' returns a lazy sequence of clojure types .. somnium.dwnload=> (doseq [v (fetch :tweets)] (prn (type v))) clojure.lang.PersistentArrayMap clojure.lang.Pe

Re: noob : congomongo to disk

2010-06-06 Thread Brian Wolf
But if print-dup is just seeing clojure.lang.PersistentArrayMap objects, why does it matter what type it contains? On Jun 5, 11:09 pm, Meikel Brandmeyer wrote: > Hi, > > Am 06.06.2010 um 01:47 schrieb Brian Wolf: > > >      java.lang.IllegalArgumentException: No method in mult

Re: noob : congomongo to disk

2010-06-06 Thread Brian Wolf
be extended to every possible data type that might be stored in a map in order to save it to a file (?) On Jun 6, 12:54 pm, Meikel Brandmeyer wrote: > Hi, > > Am 06.06.2010 um 21:46 schrieb Brian Wolf: > > > But if print-dup is just seeing clojure.lang.PersistentArrayMap > > o

Re: noob : congomongo to disk

2010-06-06 Thread Brian Wolf
I'm not sure why it does this anyways, according to congomongo documentation, 'fetch' is supoosed be returning in clojure format, not mongo. On Jun 6, 12:54 pm, Meikel Brandmeyer wrote: > Hi, > > Am 06.06.2010 um 21:46 schrieb Brian Wolf: > > >