Many properties like username, server or show do not
(of course) result in side effects.
But, available and status properties have very bad side
effect,
like sending a pres packet (for available status)and
worse,
status can't been set until available properties is set to
true.
(See code found below, in session.pas,JabberCom
V2.4.3.3)
We are currently building an instant messaging client
written in C++ with VC6.0,
using jabbercom.dll. To avoid those side effects,
we must encapsulate access like "sendMyPresence"
(our patch use sendXml) and properties
acces "available" and "status".
{---------------------------------------}
procedure TJabberSession.Set_Available(Value:
WordBool);
begin
// New Availability... send presence
_Avail := Value;
BroadcastPresence; // $FB should not be here !!
end;
{---------------------------------------}
procedure TJabberSession.Set_Status(const Value:
WideString);
begin
// New Status... send presence
if Available = false then exit; // $FB should not be
here !!
_Status := Value;
// pgm 3/17/00 - remove this.. manually broadcast
// BroadcastPresence;
end;