Browse Source

Merge pull request #31 from jonkri/master

Provide access to StanzaID generator in Network.Xmpp (`newStanzaID')
master
Jon Kristensen 13 years ago
parent
commit
32a18eecea
  1. 1
      source/Network/Xmpp.hs
  2. 5
      source/Network/Xmpp/Concurrent.hs

1
source/Network/Xmpp.hs

@ -83,6 +83,7 @@ module Network.Xmpp @@ -83,6 +83,7 @@ module Network.Xmpp
-- or IQ stanza.
, getStanza
, getStanzaChan
, newStanzaID
-- ** Messages
-- | The /message/ stanza is a /push/ mechanism whereby one entity
-- pushes information to another entity, similar to the communications that

5
source/Network/Xmpp/Concurrent.hs

@ -12,6 +12,7 @@ module Network.Xmpp.Concurrent @@ -12,6 +12,7 @@ module Network.Xmpp.Concurrent
, newSession
, writeWorker
, session
, newStanzaID
) where
import Control.Applicative((<$>),(<*>))
@ -182,3 +183,7 @@ session realm mbSasl config = runErrorT $ do @@ -182,3 +183,7 @@ session realm mbSasl config = runErrorT $ do
ses <- ErrorT $ newSession stream config
liftIO $ when (enableRoster config) $ initRoster ses
return ses
newStanzaID :: Session -> IO StanzaID
newStanzaID = idGenerator

Loading…
Cancel
Save