Online Play

Is XMLSocket anything like WinSock for Visual Basics? I wanted to know if it was possible to connect client2client instead of client2server. I remember making a chat with Visual Basics, I can prolly transfer my knowledge to Flash if XMLSocket can do the same things as WinSock.