mongoDB-0.9: A driver for MongoDB

Network.Abstract

Description

Generalize a network connection to a sink and source

Synopsis

Documentation

class Network n i o whereSource

A network controls connections to other hosts. It may want to overide to log messages or play them back. A server in the network accepts messages of type i and generates messages of type o.

Methods

connect :: n -> Server -> IOE (Connection i o)Source

Connect to Server returning the send sink and receive source, throw IOError if can't connect.

Instances

Network Internet Message Response

Connect to server. Write messages and receive replies; not thread-safe!

Network (ANetwork i o) i o 

data Connection i o Source

Constructors

Connection 

Fields

send :: i -> IOE ()
 
receive :: IOE o
 
close :: IO ()
 

data ANetwork i o Source

Constructors

forall n . Network n i o => ANetwork n 

Instances

Network (ANetwork i o) i o