Skip to content

Commit

Permalink
Merge pull request #829 from zinggAI/listener3
Browse files Browse the repository at this point in the history
remove unwanted checked exceptions from listener
  • Loading branch information
sonalgoyal authored May 14, 2024
2 parents c76ef26 + 1410583 commit fb549a9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import java.util.List;

import zingg.common.client.ZinggClientException;
import zingg.common.client.event.events.IEvent;
import zingg.common.client.util.ListMap;

Expand All @@ -22,11 +21,11 @@ public void addListener(Class<? extends IEvent> eventClass, IEventListener liste
eventListenersList.add(eventClass.getCanonicalName(), listener);
}

public void fireEvent(IEvent event) throws ZinggClientException {
public void fireEvent(IEvent event) {
listen(event);
}

private void listen(IEvent event) throws ZinggClientException {
private void listen(IEvent event) {
Class<? extends IEvent> eventClass = event.getClass();
List<IEventListener> listenerList = eventListenersList.get(eventClass.getCanonicalName());
if (listenerList != null) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
package zingg.common.client.event.listeners;

import zingg.common.client.ZinggClientException;
import zingg.common.client.event.events.IEvent;

public class IEventListener {

public void listen(IEvent event) throws ZinggClientException {
public void listen(IEvent event) {

}
}

0 comments on commit fb549a9

Please sign in to comment.