public class PacketIDFilter extends Object implements PacketFilter
Constructor and Description |
---|
PacketIDFilter(Packet packet)
Creates a new packet ID filter using the specified packet's ID.
|
PacketIDFilter(String packetID)
Creates a new packet ID filter using the specified packet ID.
|
Modifier and Type | Method and Description |
---|---|
boolean |
accept(Packet packet)
Tests whether or not the specified packet should pass the filter.
|
String |
toString() |
public PacketIDFilter(Packet packet)
packet
- the packet which the ID is taken from.public PacketIDFilter(String packetID)
packetID
- the packet ID to filter for.public boolean accept(Packet packet)
PacketFilter
accept
in interface PacketFilter
packet
- the packet to test.Copyright © 2015 Ignite Realtime. All rights reserved.