In our project we are using Scala and Reactivemongo. (I'm very new to both) When you print to the console a "pretty" Bson, it looks like this:
{ _id: BSONObjectID("52b006fe0100000100d47242"),
desc: BSONString({"_id:"BSONObjectID(52af03a5010000010036194d),"desc:"BSONString(www.foo.com"hits),"domains:"["0:"BSONString(www.foo.com)"],"func:"BSONString(Count),"maxr:"BSONInteger(5),"props:"["]"} hits),
domains: [
0: BSONString(jsonString)
],
func: BSONString(Count),
maxr: BSONInteger(5),
props: [
]
}
I need to be able to parse it back from the console into a corosponding Case Class.
Any help please?
You can check how they did it at this link in Reactivemongo documentation: http://stephane.godbillon.com/2012/10/18/writing-a-simple-app-with-reactivemongo-and-play-framework-pt-1.html