Aug 23, 2011

(Android) How to listen MessageEvent in XMPP with asmack

The asmack could not load providers from smackx.jar automatically, if any project needs listen MessageEvent (composing, delivered, displayed, offline etc.), these lines must be added manually.

After established a connection:
ProviderManager pm = ProviderManager.getInstance();

// Add extension provider
pm.addExtensionProvider("x", "jabber:x:event",new MessageEventProvider());


Anonymous said...

Excelent work. your solution solve my problem :)

Anonymous said...

What Great work, Thnaks a lot Friend