[ANN] Ma client server

Chris Muller afunkyobject at yahoo.com
Mon Feb 3 23:10:01 UTC 2003


> As far as I understood the documentation, the following should send 'aaa' and
> 
> receive 'Hello world!'?
> 
> MaServerSocket new listenOn: 12345 answer: [ :requestByteArray | 'Hello 
> world!' ].
> mySocket _ MaClientSocket hostAddress: #(127 0 0 1) port: 12345.
> mySocket sendData: #(65 65 65)
> 
> Regards, Markus

Oops..  Honestly, I haven't tried it with Strings, but it seems like it
*should* work.  Just in case, I've changed the documentation to convert that
'Hello World' to a ByteArray (#asByteArray) until I can test that.

The other thing is..  I haven't actually tried to connect to a Socket listening
in the *same* image, only different images.  It may work, I just don't know for
sure.

I hope this answers your question!  Did you find an issue?

I think also included a couple of additional files in the SAR, clientTest.ws
and serverTest.ws.  The client sends a byteArray, the server reverses it and
sends it back, which the client then verifies.

Regards,
  Chris

__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com



More information about the Squeak-dev mailing list