public boolean hasListeners(){
  return listeners != null && listeners.size() > 0;
}

public boolean hasListeners ( ) { return listeners != null && listeners . size ( ) > 0 ; }
returns true if the event dispatcher has registered listeners
