XMPPFramework - Retrieve Archived Messages From Openfire Server

后端 未结 5 1424
故里飘歌
故里飘歌 2020-12-01 04:04

I am developing a chat app for iPhone using XMPP and openfire server,OpenFire server is storing all the chat history between users but When I try to retrieve the chat histor

5条回答
  •  情歌与酒
    2020-12-01 04:36

    You have to do a request with (see http://xmpp.org/extensions/xep-0136.html) then you can take a specific time from the received result. For example:

    Send:

        
           
            
                30
            
          
       
    

    Receive:

     
         
          
          
          
          
              15
               25
               3
          
        
                 
    

    Now you choose one of starts and send (date and hour must be exacts):

      
        
         
           100
         
        
     
    

    You will receive something like this (depends the max value -> max=30, bodies=30):

       
          
             Art thou not Romeo, and a Montague?
             Neither, fair saint, if either thee dislike.
              .
              [28 more messages]
              .
             How cam'st thou hither, tell me, and therefore?              
             
          
           0
           29
           
         
      
    

提交回复
热议问题