support listeners for events

Change adds two methods to client:

- AddEventListener adds a channel to receive *APIEvents
  If this is the first listener, event monitoring is started.
- RemoveEventListener causes a channel to no longer receive *APIEvents
  If this is the last listener, event monitoring is stopped.
correct logic error on disabling monitoring
fixed some race conditions
caught closed chanel
Write to output in DockerClient.stream using fmt.Fprint instead of fmt.Fprintln.

This causes the streamed output to be exactly what the docker daemon sent, avoiding
spurious newlines in streamed build output.
Merge pull request #74 from pmorie/stream

Write to output in DockerClient.stream using fmt.Fprint instead of fmt.F...
authors: add Paul Morie
Update url to docker remote API
Merge pull request #77 from pmorie/readme

Update url to docker remote API
Add a note about how to run the tests
Merge pull request #80 from benmccann/run-tests

Add a note about how to run the tests
container: remove the setRawTerminal parameter
term: delete package
Add optional notify on successful attach
Merge pull request #81 from benmccann/success-notification

Add optional notify on successful attach
container: document the buffering limitation in AttachToContainerOptions

Related to #81.
do some fix for testing
Make uname return an error on windows instead of failing to compile because the function doesn't exist
Merge pull request #84 from edrocksit/master

Compile on windows
authors: add Ed