io.selendroid
Class UiThreadController

java.lang.Object
  extended by io.selendroid.UiThreadController
All Implemented Interfaces:
android.os.Handler.Callback

public class UiThreadController
extends Object
implements android.os.Handler.Callback

Provides facility to inject base-level UI operations (such as KeyEvent's and MotionEvent's) with more advanced synchronization than android Instrumentation class does. The key point is to loop UI thread 'manually', while waiting for the injection to be complete. This allows it to fetch and propagate unhandled exceptions, occurring in application under test and causing a crash, to the local end.


Constructor Summary
UiThreadController()
           
 
Method Summary
 boolean handleMessage(android.os.Message message)
           
 void injectInputEventWaitingForCompletion(ServerInstrumentation.InputEventSender eventSender, Object event)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UiThreadController

public UiThreadController()
Method Detail

injectInputEventWaitingForCompletion

public void injectInputEventWaitingForCompletion(ServerInstrumentation.InputEventSender eventSender,
                                                 Object event)

handleMessage

public boolean handleMessage(android.os.Message message)
Specified by:
handleMessage in interface android.os.Handler.Callback


Copyright © 2014. All rights reserved.