by
allistar >> Mon, 19 Jan 2004 0:37:36 GMT
Hi Jay,
Using the thin client capability would be a good idea for a system like this, here is how I would develop it:
- each user logs into the system as a thin client
- make a "User" class that has at least these properties:
- name, userId, emailAddress, allFriendlyUsers (this would be a collection of all users that are a "friend" of this user), isOnline
- have a dialog form that lists all "friend" users of this user, and displays whether or not they are online (red = offline, green = online or somethnig like that). When the form loads register an object notifications for each user that is displayed on the form. This is so if any details of that user changes (like their name or more importantly whether they are online) the current client will receive a notification (via the sysNotify event). On catehing that event update the display of the user (from red to green or whatever).
- on application startup register for a particular event that you will use to receive messages on the current user object (that is the user object for the current user).
- to send a message to a particular user call the "causeEvent" method on the object for the other user and pass through the details of the message. That user will receive a notification for that event, and on catching it you would display the message (or flash an icon or play a sound or however you decide to handle messages).
That's will get you started on a very basic messaging application. You could use a similar notification structure to handle live chat between multiple connected users at once.
Hope this helps,
Allistar.
--
------------------------------------------------------------------
Allistar Melville
Software Developer, Analyst
allistar@silvermoon.co.nz
Auckland, NEW ZEALAND
Silvermoon Software
Specialising in JADE development and consulting
Visit us at:
http://www.silvermoon.co.nz
*NEW* Simple web access to Jade at:
www.silvermoon.co.nz/jhp.html ------------------------------------------------------------------