I've implemented something similar for working with java.nio.ByteBuffer objects to pull apart and build network packets, but it's not packaged as a separate library right now. Look at http://github.com/geoffsalmon/bonjure/blob/master/src/bonjure/bytebuffer.clj specifically the pack, unpack, pack-bits, unpack-bits functions. Does that do what you need? There's examples in the tests http://github.com/geoffsalmon/bonjure/blob/master/test/bonjure/bytebuffer_test.clj I've only used it for one particular task, but I'd like to separate it and push it to clojars. It's about time I learn how to do that.
- Geoff On Apr 16, 9:28 pm, Scott T <scott.tho...@gmail.com> wrote: > Does anyone know of a clojure library for handling (un)packing of > binary structures? I'm looking for something similar to perl/ruby/ > python's pack(...) function or something like OCaml's bitstring > module. My initial google and clojure-contrib perusing hasn't turned > up anything obvious though I've found at least one interesting blog > post on a related subject. > > If there is such a thing in existence I'd like to know about it > otherwise I'll probably want to create it - to scratch my own itch - > and maybe someone else will have an interest in such a thing. > > -stt > > -- > 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 > athttp://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