roboguice.event.eventListener
Class UIThreadEventListenerDecorator<T>

java.lang.Object
  extended by roboguice.event.eventListener.UIThreadEventListenerDecorator<T>
All Implemented Interfaces:
EventListener<T>

public class UIThreadEventListenerDecorator<T>
extends Object
implements EventListener<T>

EventListener Decorator which executes the given event listener on the ui thread, through the provided Handler.

Author:
John Ericksen

Field Summary
protected  EventListener<T> eventListener
           
protected  android.os.Handler handler
           
 
Constructor Summary
UIThreadEventListenerDecorator(EventListener<T> eventListener, android.os.Handler handler)
           
 
Method Summary
 void onEvent(T event)
          Method called when event T is triggered.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

eventListener

protected EventListener<T> eventListener

handler

protected android.os.Handler handler
Constructor Detail

UIThreadEventListenerDecorator

public UIThreadEventListenerDecorator(EventListener<T> eventListener,
                                      android.os.Handler handler)
Method Detail

onEvent

public void onEvent(T event)
Description copied from interface: EventListener
Method called when event T is triggered.

Specified by:
onEvent in interface EventListener<T>
Parameters:
event - fired


Copyright © 2012. All Rights Reserved.