How in the world do i make a TCP Client Connection that can send and recieve?

The documentation on TCP connections is just horrible! https://developer.roku.com/docs/references/brightscript/components/rostreamsocket.md

I cannot figure out how im supposed to send and receive data as a client in a tcp connection.