org.almendra.commons.events
Class SimpleVetoableEventRegistry

java.lang.Object
  extended by org.almendra.commons.events.SimpleEventRegistry
      extended by org.almendra.commons.events.SimpleVetoableEventRegistry
All Implemented Interfaces:
ISimpleEventRegistry, IVetoableEventRegistry

public class SimpleVetoableEventRegistry
extends SimpleEventRegistry
implements IVetoableEventRegistry

Author:
Oliver Plohmann

Field Summary
 
Fields inherited from class org.almendra.commons.events.SimpleEventRegistry
lock, registry
 
Constructor Summary
SimpleVetoableEventRegistry()
          Creates a new SimpleVetoableEventRegistry object.
 
Method Summary
 java.util.List askAnyMustVeto(Event event)
           
 boolean askUserIgnoreVetos(java.util.List listOfResults, java.awt.Component componentOrNull, java.lang.String title, java.lang.String requestActionMessage)
           
 void deregister(java.lang.String eventName, IVetoableCallbackHandler handler)
           
 void register(java.lang.String eventName, IVetoableCallbackHandler handler)
           
 
Methods inherited from class org.almendra.commons.events.SimpleEventRegistry
checkEventNameValid, deregister, deregisterPrim, occured, register, registerPrim, throwNoSuchEvent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleVetoableEventRegistry

public SimpleVetoableEventRegistry()
Creates a new SimpleVetoableEventRegistry object.

Method Detail

register

public void register(java.lang.String eventName,
                     IVetoableCallbackHandler handler)
              throws java.lang.IllegalArgumentException
Specified by:
register in interface IVetoableEventRegistry
Throws:
java.lang.IllegalArgumentException

deregister

public void deregister(java.lang.String eventName,
                       IVetoableCallbackHandler handler)
                throws java.util.NoSuchElementException,
                       java.lang.IllegalArgumentException
Specified by:
deregister in interface IVetoableEventRegistry
Throws:
java.util.NoSuchElementException
java.lang.IllegalArgumentException

askAnyMustVeto

public java.util.List askAnyMustVeto(Event event)
Specified by:
askAnyMustVeto in interface IVetoableEventRegistry

askUserIgnoreVetos

public boolean askUserIgnoreVetos(java.util.List listOfResults,
                                  java.awt.Component componentOrNull,
                                  java.lang.String title,
                                  java.lang.String requestActionMessage)
Specified by:
askUserIgnoreVetos in interface IVetoableEventRegistry