BSON: fix unexported data constructor

This commit is contained in:
Scott R. Parish 2010-01-10 21:22:02 -06:00
parent 2cea5777fb
commit b18d3d54b0
3 changed files with 10 additions and 4 deletions

View file

@ -1,9 +1,8 @@
module Database.MongoDB.BSON
(
BSValue(..),
BSONObject,
BSONObject(..),
toBSONObject,
fromBSONObject,
BinarySubType(..)
)
where
@ -42,7 +41,9 @@ data BSValue
| BSMaxKey
deriving (Show, Eq, Ord)
newtype BSONObject = BSONObject { fromBSONObject :: Map.Map L8.ByteString BSValue }
newtype BSONObject = BSONObject {
fromBSONObject :: Map.Map L8.ByteString BSValue
}
deriving (Eq, Ord, Show)
toBSONObject :: [(L8.ByteString, BSValue)] -> BSONObject

5
TODO
View file

@ -5,3 +5,8 @@ BSON
----
+ support something like toSql (convert a haskell type to bson)
+ reject keys that start with "$" or "."
MongoDB
-------
+ support safe operations
+ auto-reconnection

View file

@ -10,4 +10,4 @@ Build-Depends: base,
utf8-string
Build-Type: Simple
Exposed-modules: Database.MongoDB.BSON
Other-modules: Database.MongoDB.Util
Other-modules: Database.MongoDB.Util