Authors
- Generated by root
-
Presence : TRXMLNullHandler
- Declared in:
- Presence.h
The Presence class represents an XMPP presence stanza.
Because the XMPP spec is now horribly bloated, and
the designers didn't think to include a more generic
broadcast stanza form, presence is now used for a
lot more things than presence information.
Instance Variables
Method summary
+ (NSString*)
displayStringForPresence: (unsigned char)_presence;
Returns the (currently English; should be
internationalised) display string for a
given presence. For example, will return @"Online"
when passed PRESENCE_ONLINE.
+ (unsigned char)
presenceForXMPPString: (NSString*)_presence;
Returns the online state represented by a given
XMPP string.
+ (NSString*)
xmppStringForPresence: (unsigned char)_presence;
Returns the string used by XMPP to represent a
given online state.
- (NSComparisonResult)
compare: (
Presence*)_otherPresence;
Compares two presence stanzas by their online
state.
- (id)
initWithJID: (
JID*)_jid;
Create a new presence stanza for a specified JID.
- (
JID*)
jid;
Returns the JID of the sender.
- (NSString*)
nickname;
Returns the preferred nickname set by the remote
user.
- (int)
priority;
Returns the priority set for the stanza.
- (unsigned char)
show;
Returns the online status. These are symbolic
constants and are ordered such that A being less
than B means A is more online than B.
- (NSString*)
status;
Returns the status message.
- (
PresenceType)
type;
Returns the presence type as described above.
Instance Variables for Presence Class
@protected JID* from;
Description forthcoming.
@protected NSString* message;
Description forthcoming.
@protected NSString* nickname;
Description forthcoming.
@protected unsigned char onlineStatus;
Description forthcoming.
@protected int priority;
Description forthcoming.
@protected PresenceType type;
Description forthcoming.
- Declared in:
- Presence.h
Protocol implemented by any UI component with a
presence display. This should probably be replaced
with a notification based system.
Method summary
- (void)
setPresence: (unsigned char)_status
withMessage: (NSString*)_message;
Description forthcoming.
typedef enum ... PresenceType;
Types of presence stanzas. The first two represent
normal presence information while the last four relate
to manipulation of the roster.
PRESENCE_AWAY
Constant representing an 'away' online state.
PRESENCE_CHAT
Constant representing a 'free for chat' online
state.
PRESENCE_DND
Constant representing a 'do not disturb' online
state.
PRESENCE_OFFLINE
Constant representing an 'offline' online state.
PRESENCE_ONLINE
Constant representing an 'online' online state.
PRESENCE_UNKNOWN
Constant representing an unknown online state.
PRESENCE_XA
Constant representing an 'extended away' online
state.
int PRESENCE_ICONS;
Unicode characters representing various online states