-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Backend for the persistent library using mongoDB. -- -- Backend for the persistent library using mongoDB. @package persistent-mongoDB @version 0.6.2 module Database.Persist.MongoDB withMongoDBConn :: (MonadIO m, Applicative m) => Database -> HostName -> (ConnectionPool -> m b) -> m b withMongoDBPool :: (MonadIO m, Applicative m) => Database -> HostName -> Int -> (ConnectionPool -> m b) -> m b runMongoDBConn :: MonadIO m => AccessMode -> Action m b -> ConnectionPool -> m b -- | Either a host name e.g., "haskell.org" or a numeric host -- address string consisting of a dotted decimal IPv4 address or an IPv6 -- address e.g., "192.168.0.1". type HostName = String u :: String -> UString -- | A monad on top of m (which must be a MonadIO) that may access the -- database and may fail with a DB Failure data Action m :: (* -> *) a :: (* -> *) -> * -> * -- | Type of reads and writes to perform data AccessMode :: * -- | Read-only action, reading stale data from a slave is OK. ReadStaleOk :: AccessMode -- | Read-write action, slave not OK, every write is fire & forget. UnconfirmedWrites :: AccessMode -- | Read-write action, slave not OK, every write is confirmed with -- getLastError. ConfirmWrites :: GetLastError -> AccessMode -- | Same as ConfirmWrites [] master :: AccessMode -- | Same as ReadStaleOk slaveOk :: AccessMode -- | Field with given label and typed value (=:) :: Val v => Label -> v -> Field type ConnectionPool = (Pool IOError Pipe, Database) instance Serialize ObjectId instance Val PersistValue instance (Applicative m, Functor m, MonadControlIO m) => PersistBackend Action m instance SinglePiece (Key Action entity)