mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2025-09-10 02:39:42 +02:00
s/processPacket/processStanza/ s/PacketCollector/StanzaCollector/
This commit is contained in:
parent
9328182912
commit
90a5e289f8
100 changed files with 406 additions and 406 deletions
|
@ -29,13 +29,13 @@ PacketCollector myCollector = connection.createPacketCollector(filter);
|
|||
// Normally, you'd do something with the collector, like wait for new packets.
|
||||
|
||||
// Next, create a packet listener. We use an anonymous inner class for brevity.
|
||||
PacketListener myListener = new PacketListener() {
|
||||
**public** **void** processPacket(Packet packet) {
|
||||
// Do something with the incoming packet here._
|
||||
StanzaListener myListener = new StanzaListener() {
|
||||
**public** **void** processStanza(Stanza stanza) {
|
||||
// Do something with the incoming stanza here._
|
||||
}
|
||||
};
|
||||
// Register the listener._
|
||||
connection.addPacketListener(myListener, filter);
|
||||
connection.addStanzaListener(myListener, filter);
|
||||
```
|
||||
|
||||
Standard Stanza Filters
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue