getHierarchyViewer()抛出NoClassDefFoundError

时间:2012-11-10 21:56:37

标签: android

我试图通过IChimpDevice获取android HierarchyViewer,我的代码看起来像这样

public HierarchyViewer GetHierarchyViewer()
{
    return mDevice.getHierarchyViewer();
}

我已经用这种方式初始化了mDevice:

mDevice = mChimpchat.waitForConnection(TIMEOUT, ".*");
if ( mDevice == null ) {
    throw new RuntimeException("Couldn't connect.");
}
mDevice.wake();

当我致电getHierarchyViewer()时,我得到了这个例外:

Exception in thread "main" java.lang.NoClassDefFoundError: com/android/hierarchyviewerlib/device/DeviceBridge
    at com.android.chimpchat.hierarchyviewer.HierarchyViewer.setupViewServer(HierarchyViewer.java:46)
    at com.android.chimpchat.hierarchyviewer.HierarchyViewer.<init>(HierarchyViewer.java:42)
    at com.android.chimpchat.adb.AdbChimpDevice.getHierarchyViewer(AdbChimpDevice.java:96)
    at ChimpChatWrapper.GetHierarchyViewer(ChimpChatWrapper.java:44)
    at ViewService.main(ViewService.java:17)

有人可以帮助解释为什么找不到DeviceBridge类吗?

0 个答案:

没有答案