Introduce IWebsocket interface so that the JWS library can play ball
with DI tools like Google Guice.
Fix some bugs around CLOSE_WAIT, partial buffer hangs, deadlocks, etc.
(Commented in the code - can remove if ported back to the mothership.)
May have messed up tabs vs. spaces here and there - was on accident.  It
would be better if JWS had a .project file that enforced a code style.