Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@dcolish
Created February 27, 2013 05:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dcolish/c810e10ea928d78c2ca2 to your computer and use it in GitHub Desktop.
Save dcolish/c810e10ea928d78c2ca2 to your computer and use it in GitHub Desktop.
(defn write-builder [cube & ats]
(reduce (fn [builder [dim value]] (doto builder (.at dim value)))
(WriteBuilder. cube)
(filter #(not (empty? %)) ats)))
(defn read-builder [cube & ats]
(reduce (fn [builder [dim bucket value]] (doto builder (.at dim bucket value)))
(ReadBuilder. cube)
(filter #(not (empty? %)) ats)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment