Skip to content

Instantly share code, notes, and snippets.

@abrightwell
Created April 19, 2012 16:02
Show Gist options
  • Select an option

  • Save abrightwell/2421990 to your computer and use it in GitHub Desktop.

Select an option

Save abrightwell/2421990 to your computer and use it in GitHub Desktop.
interface Foo {
public void update();
}
class abstract Bar {
private List<Foo> listeners;
...
public void fireEvent() {
for (Foo listener : listeners) {
listener.update();
}
}
}
class Baz extends Bar {
public void doSomething() {
this.fireEvent();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment