synchronized (listeners) {
copy = new HashMap<PacketListener, PacketFilter>(listeners);
}
for (Entry<PacketListener, PacketFilter> entry : copy.entrySet()) {
PacketListener listener = entry.getKey();
PacketFilter filter = entry.getValue();
if (filter == null || filter.accept(packet)) {
listener.processPacket(packet);
/*
* A stream can only be accepted once. Else an exception is
* thrown:
*
* java.lang.IllegalStateException: This IncomingTransferObject