package jrummikub.util; import java.util.HashSet; public class Event2 implements IEvent2 { private HashSet> listeners = new HashSet>(); @Override public void add(IListener2 listener) { listeners.add(listener); } @Override public void remove(IListener2 listener) { listeners.remove(listener); } public void fire(T1 value1, T2 value2) { for (IListener2 listener : listeners) { listener.fire(value1, value2); } } }