index of namespace default
 
 index of project tksdl_net
 
 index of module tksdl_net

Class tksdl_net.TCPSocket


SynopsisRepresents an SDL_net TCP socket

  Base classes:
  Methods:

Method accept
Accept client connection and return new TCPSocket object
Signature
accept():TCPSocket
Returns
Description

This is a wrapper for the SDLNet_TCP_Accept() native function.

 
 top of page
Method close
Close socket
Signature
close()

 
 top of page
Method getPeerAddress
Query peer IPV4 address and port number
Signature
getPeerAddress():IPAddress
Returns
Description

This is a wrapper for the SDLNet_TCP_GetPeerAddress() native function.

 
 top of page
Method open
Open socket
Signature
open(IPAddressip)
Arguments
IPAddressip
Description

This is a wrapper for the SDLNet_TCP_Open() native function.

 
 top of page
Method recv
Receive data
Signature
recv(Buffernetbuf,
  intnum 
  )  
Arguments
Buffernetbuf
intnum

 
 top of page
Method send
Send data
Signature
send(Buffernetbuf,
  intnum 
  )  
Arguments
Buffernetbuf
intnum

 
 top of page
Method sendString
Send string
Signature
sendString(Strings)
Arguments
Strings

 
 top of page
Method socketReady
Check whether this socket has been marked as active.
Signature
socketReady():boolean
Returns
boolean
Description

This is a wrapper for the SDLNet_SocketReady() native function.

 
 top of page
 

Project Modules:tksdl_net 
Project Classes:IPAddress , Network , TCPSocket , UDPPacket , UDPSocket 
Project Functions:
All Namespaces:default , graph , ui 
All Projects:core , eqxmms , ShaderVG , ShaderVG_Text , tkanalogrytm , tkchipmunk , tkclap , tkfileutils , tkfreeglut , tkfreetype2 , tkfreeverb , tkmath , tkmidi , tkmidipipe , tkminnie , tkoldmath , tkopengl , tkportaudio , tkradiastools , tksamplechain , tksampleedit , tksampler , tksdl , tksdl_net , tksidplay2 , tkspeexdsp , tksqlite , tktriangulate , tkui , tkvst2 , tkzip , ui , yingtest 


auto-generated by "DOG", the TkScript document generator. Thu, 11/Dec/2025 13:42:00