On Sunday 21 December 2008 10:18, chris wrote: > Right, waking up a bit. > > I would like, at some point, to serialize a bunch of structures to a > byte stream. > > They are the mapped structs (struct :data1 :data2). > > Lets say I would like to do this generically, I need a function that > takes a keyword and returns an integer. > I will write out a mapping from integer to name to the file.
You should at least consider just using the Clojure printer and reader for your serialization / deserialization. > ... > > Is there a keywords namespace that single colon keywords go into? Keywords and symbols are the same insofar they they all live in namespace. The notation is consistent between the two: user=> (namespace :foo/bar) "foo" user=> (name :foo/bar) "bar" > Chris Randall Schulz --~--~---------~--~----~------------~-------~--~----~ 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 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 -~----------~----~----~----~------~----~------~--~---