def write( msg )
      $stderr.puts "--> #{msg}" if $DEBUG
      socket.write( msg )
    rescue KJess::NetworkError
      close
      raise
    rescue => e
      close
      raise Error, "Could not write to #{host}:#{port}: #{e.class}: #{e.message}", e.backtrace
    end
def write( msg )
      $stderr.puts "--> #{msg}" if $DEBUG
      socket.write( msg )
    rescue KJess::NetworkError
      close
      raise
    rescue => e
      close
      raise Error, "Could not write to #{host}:#{port}: #{e.class}: #{e.message}", e.backtrace
    end
Internal: write the given item to the socket

 msg - the message to write

 Returns nothing