AIMCC Technote 14

Real-Time IM (RTIM)


Q: What is Real-Time IM?
A: Real-Time IM lets you and your buddy see what the other person is typing in real-time, as it is being typed, right in the IM window. Real-Time IM is a session type of IAccImSession and is a DIM session. Please refer to the DIM(Direct IM) technote at AIMCC Technote 9. Below are some properties of an Real-Time IM Session:


Q: What is a Real-Time IM preference aimcc.im.direct.receiveRtim?
A: Set it to TRUE before creating a DIM session to indicate in the proposal that Real-Time IM is requested, and to be able to receive Real-Time IM proposals.

Q: What is a Real-Time IM property AccImSessionProp_LocalWantsRtim?
A: Use AccImSessionProp_LocalWantsRtim to get/set whether an IAccImSession can receive Real-Time IMs. aimcc.im.direct.receiveRtim is only applied at IAccImSession creation; thereafter, IAccImSessionProp_LocalWantsRtim should be used. Also, aimcc.im.direct.receiveRtim applies to all (future) Real-Time IM sessions and AccImSessionProp_LocalWantsRtim applies to an individual Real-Time IM session.

Q: What is a Real-Time IM property AccImSessionProp_RemoteWantsRtim?
A: Use AccImSessionProp_RemoteWantsRtim to get whether an IAccImSession can send Real-Time IMs. Test this flag when a proposal is received to see whether the proposer wants Real-Time IM.

Q: What is a Real-Time IM property AccImFlags_Rtim?
A: Use AccImFlags_Rtim to set/get whether an IAccIm is a Real-Time IM.

Q: How does one initiate a Real-Time IM session?
A: To start a new Real-Time IM session, follow the instructions for starting a DIM (Please refer to the DIM tech note at AIMCC Technote 9). In addition, you can, if desired, optionally check to see if buddy is Real-Time IM capable and if not, message the proposer and halt the creation. before initiating the proposal, set the preference aimcc.im.direct.receiveRtim to specify whether newly created IAccImSessions can receive Real-Time IMs. And then, you can also set AccImSessionProp_LocalWantsRtim.

Q: How does one handle a Real-Time IM session invitation?
A: Basically follow the same steps as when receiving a DIM (Please refer to the DIM tech note at AIMCC Technote 9) and in addition do the following. On receiving a proposal, check to see if the flag AccImSessionProp_RemoteWantsRtim is set. The preference aimcc.im.direct.receiveRtim to specify that newly created IAccImSessions can receive Real-Time IMs can be set by the user.

Q: What are the preferences, properties and flags to be aware of in Real-Time IM?
A: AccImFlags_Rtim, AccImSessionProp_RemoteWantsRtim, aimcc.im.direct.receiveRtim, AccImSessionProp_LocalWantsRtim.

Q: How does one handle the data received in an Real-Time IM?
A: Check the AccImFlags_Rtim to see whether an IAccIm is a Real-Time IM and handle it the way you choose in the OnImReceived(..) callback. That is how it is distinguished from a regular IM or a DIM. It is important to set this flag before sending an Real-Time IM before doing the SendIM(..). Also, when a previously received IM is a Real-Time IM, newly received IM text replaces all of the previous IM text on the Real-Time IM display. Also, in an Real-Time IM session when a user sends an IM by hitting the send button, AccImFlags_Rtim should not be set, that is how the IM is "committed" to the regular IM display window.

Q: How can I tell when a Real-Time IM session ends, and how can I tell when a Real-Time IM session fails to start?
A: Similar to how you handle a DIM, refer to the DIM technote (Please refer to the DIM tech note at AIMCC Technote 9).

 

 rev. 2009/03/06