The getOutputStream() method returns an output stream which writes data to the socket.
getOutputStream()
Most of the time you'll chain the raw output stream to some other output stream or writer class to more easily handle the data.