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
- setGroupchatSubject :: String -> String -> XMPP ()
- data Occupant = Occupant {}
- data Role
- = RModerator
- | RParticipant
- | RNone
- | RVisitor
- data Affiliation
- data GroupchatPresence
- doGroupchatPresence :: XMLElem -> (GroupchatPresence, Occupant)
- isGroupchatPresence :: StanzaPredicate
- type Nick = String
- type JID = String
- adminGroupchat :: Either Nick JID -> String -> String -> Maybe String -> XMPP ()
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.
Groupchat occupant.
data GroupchatPresence Source
Groupchat presence. Leave, Kick and Ban are role change too of course, but it separated for simplicity sake.
doGroupchatPresence :: XMLElem -> (GroupchatPresence, Occupant)Source
Create groupchat presence from stanza.
isGroupchatPresence :: StanzaPredicateSource
Handler for groupchat events (joinleavekicksbansetc).