Java 类android.support.test.rule.UiThreadTestRule 实例源码

项目:edx-app-android    文件:PresenterActivityScreenshotTest.java   
public UiThreadInvocationHandler(@NonNull UiThreadTestRule uiThreadTestRule, @NonNull ViewT impl) {
    this.uiThreadTestRule = uiThreadTestRule;
    this.impl = impl;
}
项目:edx-app-android    文件:PresenterActivityScreenshotTest.java   
@SuppressWarnings("unchecked")
@NonNull
public static <ViewT> ViewT newProxyInstance(@NonNull UiThreadTestRule uiThreadTestRule, @NonNull ViewT view, @NonNull Class<ViewT> viewType) {
    return (ViewT) Proxy.newProxyInstance(viewType.getClassLoader(), new Class<?>[]{viewType}, new UiThreadInvocationHandler(uiThreadTestRule, view));
}