org.jivesoftware.smack.filter
Class PacketIDFilter
java.lang.Object
org.jivesoftware.smack.filter.PacketIDFilter
- All Implemented Interfaces:
- PacketFilter
public class PacketIDFilter
- extends Object
- implements PacketFilter
Filters for packets with a particular packet ID.
- Author:
- Matt Tucker
Constructor Summary |
PacketIDFilter(String packetID)
Creates a new packet ID filter using the specified packet ID. |
Method Summary |
boolean |
accept(Packet packet)
Tests whether or not the specified packet should pass the filter. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PacketIDFilter
public PacketIDFilter(String packetID)
- Creates a new packet ID filter using the specified packet ID.
- Parameters:
packetID
- the packet ID to filter for.
accept
public boolean accept(Packet packet)
- Description copied from interface:
PacketFilter
- Tests whether or not the specified packet should pass the filter.
- Specified by:
accept
in interface PacketFilter
- Parameters:
packet
- the packet to test.
- Returns:
- true if and only if packet passes the filter.
Copyright © 2003 Jive Software.