Advertisement
Guest User

Untitled

a guest
Jun 12th, 2014
217
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. (defn convert-line-to-map-entry [line]
  3.         (apply hash-map (str/split line #":")))
  4.  
  5. (defn read-sensor-data
  6.   "reads the file and returns a map of the following format:
  7.  {\"key\" \"value\"}"
  8.   [file-path]
  9.           (with-open [rdr (io/reader file-path)]
  10.             (doseq [line (line-seq rdr)]
  11.               ;(println line)
  12.               (convert-line-to-map-entry line))))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement