Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Understanding tcp

From: Rebolinth:nodep:dds:nl at: 15-Aug-2003 22:50

Quoting patrick <[patrick--philipot--laposte--net]>: Hello Patrick, Well yes basicly i gave you a server to understand the working of the client ;-) Never the less Rebol tcp client connections work the same way..only different...hehe Basicly the idea behind the 'ports under rebol is very nice, because a file a serial a tcp an udp a console a sound a crypting they are all ports .... Coming back to your server connection, If you know how the data is sent from the server to you client (line based or raw binary?) you should change the behaviour of your client on this... this sets your network timeout on the revceive or send over network ports... system/options/schemes/timeout: 60 (default its 30 seconds) The best thing to make a client is that, for very write action you should also read (because you probably will receive data after writing?) or reverse... here an exmaple: b: open/direct/binary/no-wait tcp://localhost:21 print copy b the print copy b will return for you the data from the port putting the above in a loop with your data to send and the expected result to read should make a nice client... Try it...dont forget to read the online docs.. takes some minutes to understand but then you have someting nice ;-) Dont forget to peek in the library section too.. (R)egards, Norman.