IJabberRoster
This interface contains all the information in and
about the roster.
Properties
- Count [int] - How many items are in the Roster?
- Items[index: int] - Return a specific IJabberRosterItem
(see below for more interface details on Roster Items).
- Session - Returns the IJabberSession which this roster is
connected to.
Methods
- Add(NewJID: string; Nick: string): IJabberRosterItem
-
This method allows you to add a new item to
the internal roster. This does not actually
send anything to the server. Returns the new
IJabberRosterItem that was created.
- FindUserID(userid: string): IJabberRosterItem
-
This allows you to search the internal roster
for a specific JID or a UserID. IE, you can
send something like FindUserID('foo@jabber.com')
as well as FindUserID('jabber:foo@jabber.com')
The method returns either 'nil' if the item was not
found or the actual IJabberRosterItem.
- FindNick(nick: string): IJabberRosterItem
-
Returns either 'nil' or the RosterItem object
which matches with the nick-name passed.
- Delete(index: integer)
- Delete an item from the roster
- Clear
- Clears the entire Roster.
- Fetch
- Get the current roster from the server and fill
the internal contents with IJabberRosterItem objects.
IJabberRosterItem
This interface contains the details for a specific item
in the roster. Note that all presence and resource information
has been removed from Roster Items. All of this information
is available by using the IJabberSession.GetPres method
and using the resulting IJabberPres objects.
Properties
- NickName [string] - the nickname given to this roster item.
- JID [string] - The fully qualified JID for this user. This
is normally something like:
'user@server.com/user-resource1' Note that the JID may
not ALWAYS include the resource.
- UserID [string] - Just the userid portion of the JID,
ie, 'user@server.com' from the above example.
- GroupCount [int] - how many groups is this user in?
- Group[index: int] - get a specific group.
- Subscription [JabberSubscriptionType] - The current subscription
type.. to indicate to|from|both|none, etc..
- Ask [string] - the current 'ask' state for this roster item.
Would indicate if a subscribe request is pending or
not.
- Roster [IJabberRoster] - The Roster Interface which this item
belongs to.
Methods
- AddGroup(NewGrp: string)
- Add a group to the roster item
- DelGroup(DelGrp: string)
- Remove a group from the list.
- ClearGroups
- Clear all the groups this user belongs to.
- InGroup(Grp: string): bool
- Does this user belong to a
specific group or not?
- Update
- Send the current roster information back to the
server so it gets stored permanently there.