Re: Re: Handling java streams..
Calling (- stream .iterator iterator-seq) should give the desired result. On Wednesday, October 1, 2014 6:39:11 AM UTC-7, José Ricardo wrote: By nicer I meant something like being able to use, for example, map and filter, just like I can do on a java.util.ArrayList (in clojure) and on a Stream (in java). On Saturday, September 27, 2014 1:47:38 AM UTC-4, Sean Corfield wrote: On Fri, Sep 26, 2014 at 11:51 AM, José Ricardo zehz...@gmail.com wrote: Hi, I'm not sure if resurrecting this thread is the right approach, but what about Java 8 Streams (java.util.stream)? Are there any libraries out there for making java 8 streams handling nicer? :) Well, this thread is certainly a blast from the past :) Can you be a bit more specific about what you'd like to see nicer with Java 8 streams, and what you'd like to see in a Clojure wrapper? I ask because Java 8 is the first version that I've been interested in since I felt it went off the rails with Java 5 - and streams are part of what makes Java 8 attractive again :) -- Sean A Corfield -- (904) 302-SEAN An Architect's View -- http://corfield.org/ World Singles, LLC. -- http://worldsingles.com/ Perfection is the enemy of the good. -- Gustave Flaubert, French realist novelist (1821-1880) -- 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 --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Re: Handling java streams..
It's use cases like these that make me wish clojure.lang.Seqable and the like were protocols. Ah, one can dream... On Sunday, October 5, 2014 11:59:15 PM UTC-4, Zach Tellman wrote: Calling (- stream .iterator iterator-seq) should give the desired result. On Wednesday, October 1, 2014 6:39:11 AM UTC-7, José Ricardo wrote: By nicer I meant something like being able to use, for example, map and filter, just like I can do on a java.util.ArrayList (in clojure) and on a Stream (in java). On Saturday, September 27, 2014 1:47:38 AM UTC-4, Sean Corfield wrote: On Fri, Sep 26, 2014 at 11:51 AM, José Ricardo zehz...@gmail.com wrote: Hi, I'm not sure if resurrecting this thread is the right approach, but what about Java 8 Streams (java.util.stream)? Are there any libraries out there for making java 8 streams handling nicer? :) Well, this thread is certainly a blast from the past :) Can you be a bit more specific about what you'd like to see nicer with Java 8 streams, and what you'd like to see in a Clojure wrapper? I ask because Java 8 is the first version that I've been interested in since I felt it went off the rails with Java 5 - and streams are part of what makes Java 8 attractive again :) -- Sean A Corfield -- (904) 302-SEAN An Architect's View -- http://corfield.org/ World Singles, LLC. -- http://worldsingles.com/ Perfection is the enemy of the good. -- Gustave Flaubert, French realist novelist (1821-1880) -- 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 --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Re: Handling java streams..
By nicer I meant something like being able to use, for example, map and filter, just like I can do on a java.util.ArrayList (in clojure) and on a Stream (in java). On Saturday, September 27, 2014 1:47:38 AM UTC-4, Sean Corfield wrote: On Fri, Sep 26, 2014 at 11:51 AM, José Ricardo zehz...@gmail.com javascript: wrote: Hi, I'm not sure if resurrecting this thread is the right approach, but what about Java 8 Streams (java.util.stream)? Are there any libraries out there for making java 8 streams handling nicer? :) Well, this thread is certainly a blast from the past :) Can you be a bit more specific about what you'd like to see nicer with Java 8 streams, and what you'd like to see in a Clojure wrapper? I ask because Java 8 is the first version that I've been interested in since I felt it went off the rails with Java 5 - and streams are part of what makes Java 8 attractive again :) -- Sean A Corfield -- (904) 302-SEAN An Architect's View -- http://corfield.org/ World Singles, LLC. -- http://worldsingles.com/ Perfection is the enemy of the good. -- Gustave Flaubert, French realist novelist (1821-1880) -- 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 --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Handling java streams..
On Monday, June 27, 2011 5:50:52 PM UTC-4, Ken Wesson wrote: On Mon, Jun 27, 2011 at 6:52 AM, Andreas Liljeqvist bon...@gmail.com javascript: wrote: most clojurists(?) seems to roll their own solution. Probably because it's [clojure.java.io] not in clojure.core, which means a) it isn't found by searching the docs in many of the usual ways; {snip} My go-to doc is the cheatsheet, and I do see mention of it there. -- 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 --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Re: Handling java streams..
Hi, I'm not sure if resurrecting this thread is the right approach, but what about Java 8 Streams (java.util.stream)? Are there any libraries out there for making java 8 streams handling nicer? :) On Tuesday, June 28, 2011 2:18:13 PM UTC-4, Sean Corfield wrote: On Tue, Jun 28, 2011 at 10:40 AM, Ken Wesson kwes...@gmail.com javascript: wrote: How else do you propose to explain the observation that if it isn't in clojure.core, it tends to be underused? :) Well, that's your observation so it's rather circular logic :) -- Sean A Corfield -- (904) 302-SEAN An Architect's View -- http://corfield.org/ World Singles, LLC. -- http://worldsingles.com/ Railo Technologies, Inc. -- http://www.getrailo.com/ Perfection is the enemy of the good. -- Gustave Flaubert, French realist novelist (1821-1880) -- 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 --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Re: Handling java streams..
On Fri, Sep 26, 2014 at 11:51 AM, José Ricardo zehzi...@gmail.com wrote: Hi, I'm not sure if resurrecting this thread is the right approach, but what about Java 8 Streams (java.util.stream)? Are there any libraries out there for making java 8 streams handling nicer? :) Well, this thread is certainly a blast from the past :) Can you be a bit more specific about what you'd like to see nicer with Java 8 streams, and what you'd like to see in a Clojure wrapper? I ask because Java 8 is the first version that I've been interested in since I felt it went off the rails with Java 5 - and streams are part of what makes Java 8 attractive again :) -- Sean A Corfield -- (904) 302-SEAN An Architect's View -- http://corfield.org/ World Singles, LLC. -- http://worldsingles.com/ Perfection is the enemy of the good. -- Gustave Flaubert, French realist novelist (1821-1880) -- 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 --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Aw: Re: Handling java streams..
Hi, Am Montag, 27. Juni 2011 23:50:52 UTC+2 schrieb Ken Wesson: a) it isn't found by searching the docs in many of the usual ways; Is that really so hard? http://clojure.github.com/clojure top-right TOC: clojure.java.io If I look for stream handling, wouldn't that sound interesting? Sadly the mind-reading documentation site is not ready, yet. Until then I recommend to read (and experiment with) one or two random functions from the reference every day. In that way you (not you, Ken. you in general the newbie) get an overview and get familiar with the docs. Sincerely Meikel -- 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
Re: Re: Handling java streams..
On Tue, Jun 28, 2011 at 2:19 AM, Meikel Brandmeyer m...@kotka.de wrote: Hi, Am Montag, 27. Juni 2011 23:50:52 UTC+2 schrieb Ken Wesson: a) it isn't found by searching the docs in many of the usual ways; Is that really so hard? http://clojure.github.com/clojure top-right TOC: clojure.java.io If I look for stream handling, wouldn't that sound interesting? Sadly the mind-reading documentation site is not ready, yet. Until then I recommend to read (and experiment with) one or two random functions from the reference every day. In that way you (not you, Ken. you in general the newbie) get an overview and get familiar with the docs. Well, of course *I* know this. But I guess a lot of people mostly just keep a browser tab parked at http://clojure.github.com/clojure/clojure.core-api.html and occasionally go to it and hit ctrl+F or F3 or whatever the usual search hotkey is in Windoze apps, with results similar to using find-doc except without cluttering their REPL history or backscroll or getting scrolled out of view by using the REPL to try things. How else do you propose to explain the observation that if it isn't in clojure.core, it tends to be underused? :) -- Protege: What is this seething mass of parentheses?! Master: Your father's Lisp REPL. This is the language of a true hacker. Not as clumsy or random as C++; a language for a more civilized age. -- 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
Re: Re: Handling java streams..
On Tue, Jun 28, 2011 at 10:40 AM, Ken Wesson kwess...@gmail.com wrote: How else do you propose to explain the observation that if it isn't in clojure.core, it tends to be underused? :) Well, that's your observation so it's rather circular logic :) -- Sean A Corfield -- (904) 302-SEAN An Architect's View -- http://corfield.org/ World Singles, LLC. -- http://worldsingles.com/ Railo Technologies, Inc. -- http://www.getrailo.com/ Perfection is the enemy of the good. -- Gustave Flaubert, French realist novelist (1821-1880) -- 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
Re: Handling java streams..
Yes, bit ashamed that I didn't know that.. Kind of surprised though that not many seem to use it, most clojurists(?) seems to roll their own solution. Thanks. 2011/6/27 Alan Malloy a...@malloys.org clojure.java.io? On Jun 26, 2:25 pm, Andreas Liljeqvist bon...@gmail.com wrote: Are there any libraries out there for making java stream handling nicer? My current project involves reading images from zipfiles, scaling them and then write them to a new zipfile. Any code I have seen involve mostly writing java in clojure and setting up buffers and such. Certainly I could do that, but it leaves me wondering if Java interop have to be such a pain. I would think one could patternize IO ops for most standard uses. Might just be my less than fresh Java knowledge acting up... Thanks. -- 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 -- 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
Re: Handling java streams..
On Mon, Jun 27, 2011 at 6:52 AM, Andreas Liljeqvist bon...@gmail.com wrote: Yes, bit ashamed that I didn't know that.. Kind of surprised though that not many seem to use it, most clojurists(?) seems to roll their own solution. Probably because it's not in clojure.core, which means a) it isn't found by searching the docs in many of the usual ways; b) it isn't in the various intro to clojure books that have been popping up; and c) using it takes a bit of additional effort compared to using stuff from clojure.core Yes, I know rolling your own likely takes more effort than adding an import line and widening the scope of doc searches. Go figure. It gets worse, of course, when the library isn't in the main clojure jar either, so that project dependencies have to be added, additional files downloaded, and suchlike, and an even wider doc search is needed to find the thing. So we see more frequent overlooking of things in clojure.set etc. than in clojure.core, more frequent still when it's in contrib, and more frequent still when it's in neither the clojure jar nor the contrib jar. (Which, with 1.3's breakup of contrib, will be almost everything not in core.) -- Protege: What is this seething mass of parentheses?! Master: Your father's Lisp REPL. This is the language of a true hacker. Not as clumsy or random as C++; a language for a more civilized age. -- 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
Re: Handling java streams..
At this point I'll just put in a plug for the Clojure Atlas: typing stream into that yields several results that cover clojure.java.io/input-stream etc. On Mon, Jun 27, 2011 at 3:52 AM, Andreas Liljeqvist bon...@gmail.com wrote: Yes, bit ashamed that I didn't know that.. Kind of surprised though that not many seem to use it, most clojurists(?) seems to roll their own solution. -- 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
Handling java streams..
Are there any libraries out there for making java stream handling nicer? My current project involves reading images from zipfiles, scaling them and then write them to a new zipfile. Any code I have seen involve mostly writing java in clojure and setting up buffers and such. Certainly I could do that, but it leaves me wondering if Java interop have to be such a pain. I would think one could patternize IO ops for most standard uses. Might just be my less than fresh Java knowledge acting up... Thanks. -- 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
Re: Handling java streams..
clojure.java.io? On Jun 26, 2:25 pm, Andreas Liljeqvist bon...@gmail.com wrote: Are there any libraries out there for making java stream handling nicer? My current project involves reading images from zipfiles, scaling them and then write them to a new zipfile. Any code I have seen involve mostly writing java in clojure and setting up buffers and such. Certainly I could do that, but it leaves me wondering if Java interop have to be such a pain. I would think one could patternize IO ops for most standard uses. Might just be my less than fresh Java knowledge acting up... Thanks. -- 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