powered by Jive Software

Listener or collector

i have this problem (once again)…

after i log in to the server i am calling to another class.

this class initialize the listeners.

now when i am not logged in… another client (exodus) sends me some message or requests.

when i log in (with smack)… the listener doesnt catch the offline message that were sent to me.

how the listener works?

should i initialize the listener immidiatly after i log in?

because i dont unerstand if as soon as i log in the server sends me all the messages that he kept… or maybe the server sends me the message only after i initialize the listeners?

did u understand my question?


After you have created a new connection and before you log into the server, you could add any listener you want to the connection. This will prevent you from not reacting to received packets while you were setting up the listeners.

– Gato

i finnally initialized all the listeners after i logged in and in that way i get the ofline message and packetsthat were sent to me while i was offline.