tcpsocket: add a tcpsocket class.