org.apache.s4.core.gen
Class OverloadDispatcherGenerator

java.lang.Object
  extended by org.apache.s4.core.gen.OverloadDispatcherGenerator

public class OverloadDispatcherGenerator
extends java.lang.Object

This class generates a proxy to enable dispatching of events to methods of processing elements based on the runtime type of the event.

When an event is transferred to a processing element, the generated proxy finds the corresponding onEvent method with the event type argument matching the current parameter and calls this method.

If there is no exact match, the closest type in the hierarchy of events is used.

If there is still no match, an error statement is logged and the event is ignored (not processed).


Constructor Summary
OverloadDispatcherGenerator()
           
OverloadDispatcherGenerator(java.lang.Class<?> targetClass)
           
 
Method Summary
 java.lang.Class<?> generate()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OverloadDispatcherGenerator

public OverloadDispatcherGenerator()

OverloadDispatcherGenerator

public OverloadDispatcherGenerator(java.lang.Class<?> targetClass)
Method Detail

generate

public java.lang.Class<?> generate()