Implementation of Multi-User Chat, according to XEP-0045. This API needs more thought and will change.
- matchesBare :: String -> StanzaPredicate
- joinGroupchat :: String -> String -> Maybe String -> XMPP ()
- leaveGroupchat :: String -> XMPP ()
- isGroupchatMessage :: StanzaPredicate
- isGroupchatPrivmsg :: String -> StanzaPredicate
- sendGroupchatMessage :: String -> String -> XMPP ()
- sendGroupchatPrivateMessage :: String -> String -> String -> XMPP ()
- getMessageSubject :: XMLElem -> Maybe String
- data Occupant = Occupant {
- occRole :: Role
- occAffiliation :: Affiliation
- occNick :: String
- occJid :: Maybe String
- data Role
- = RModerator
- | RParticipant
- | RNone
- | RVisitor
- data Affiliation
- doOccupant :: XMLElem -> Occupant
- isGroupchatPresence :: StanzaPredicate
Documentation
matchesBare :: String -> StanzaPredicateSource
Return true if the stanza is from a JID whose "username@server" part matches the given string.
Join groupchat.
leaveGroupchat :: String -> XMPP ()Source
Leave groupchat.
isGroupchatMessage :: StanzaPredicateSource
Return true if the stanza is a message of type "groupchat".
isGroupchatPrivmsg :: String -> StanzaPredicateSource
Return true if the stanza is a private message in the named room.
Send a groupchat message.
sendGroupchatPrivateMessageSource
Send a private message in a chat room.
Occupant data strucuture.
Occupant | |
|
doOccupant :: XMLElem -> OccupantSource
Create occupant from stanza. TODO: kickbanchange statuschange nick/etc parse
isGroupchatPresence :: StanzaPredicateSource
Handler for groupchat events (joinleavekicksbansetc).