When your server has received an instant message for you, it will pass it on to your client by issuing it an RX_MSG message.
The format for an RX_MSG message is:
RX_MSG
address
message
where
| address | is the (alleged) address of the sending party; |
| message | is an envelop whose data field contains the message you are receiving. |
Upon receiving this message, your client should decode the envelop and display the message text on your screen, or process it in any other manner that you have dictated, such as logging it to a file. This message may include sequencing information, which is helpful for reordering out of order messages* or detecting lost messages. For more information, see Exchanging Messages and Message Envelops.
*Beware, your chat partner can deceive you. If he has a custom-built ODSIMS client that allows sequence number tampering, he can deliberately issue out-of-order messages to test your reaction to certain news, and then quickly "precede" it by a customized disclaimer if your reaction was unfavorable. :-)