Logcat停止了eclipse的工作

时间:2011-05-13 09:56:58

标签: android eclipse logcat

Logcat在eclipse上给我这个错误:无法创建视图:对于输入字符串:“”在线程“”

有关错误的详细信息

java.lang.NumberFormatException: For input string: ""In Thread""
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
at java.lang.Integer.parseInt(Integer.java:470)
at java.lang.Integer.parseInt(Integer.java:514)
at com.android.ddmuilib.logcat.LogFilter.loadFromString(LogFilter.java:134)
at com.android.ide.eclipse.ddms.views.LogCatView$FilterStorage.getFilterFromStore(Unknown Source)
at com.android.ddmuilib.logcat.LogPanel.createFilters(LogPanel.java:1248)
at com.android.ddmuilib.logcat.LogPanel.createControl(LogPanel.java:452)
at com.android.ddmuilib.Panel.createPanel(Panel.java:29)
at com.android.ide.eclipse.ddms.views.LogCatView.createPartControl(Unknown Source)
at org.eclipse.ui.internal.ViewReference.createPartHelper(ViewReference.java:367)
at org.eclipse.ui.internal.ViewReference.createPart(ViewReference.java:226)
at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:595)
at org.eclipse.ui.internal.WorkbenchPage$ActivationList.setActive(WorkbenchPage.java:4212)
at org.eclipse.ui.internal.WorkbenchPage$18.runWithException(WorkbenchPage.java:3271)
at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3468)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3115)
at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(WorkbenchAdvisor.java:803)
at org.eclipse.ui.internal.Workbench$28.runWithException(Workbench.java:1384)
at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3468)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3115)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2316)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2221)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:500)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:493)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:113)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:368)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:559)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
at org.eclipse.equinox.launcher.Main.run(Main.java:1311)

知道如何解决这个问题。 似乎问题出现在eclipse中,因为logcat在终端“cmd”

中工作正常

2 个答案:

答案 0 :(得分:1)

我遇到了同样的问题,因为为“MMS:app”添加了一个过滤器。过滤器名称/设置中的:使Eclipse中的Log Cat失败。

请参阅此处以获取有关此内容的另一个讨论:

Logcat View fails with "Could not create the view: For input string: "our" "

解决方案的复制和粘贴:

  

我之后logcat视图崩溃了   插入一个包含“:”的过滤器   filtername。我解决了这个问题   通过更改文件中的设置   ” .metadata / .plugins / org.eclipse.core.runtime / .settings /   com.android.ide.eclipse.ddms.prefs”   放在eclipse的工作区。   com.android.ide.eclipse.ddms.logcat.filters =   是故障设置的关键。

答案 1 :(得分:0)

正如我所见,你的字符串必须看起来像“Is Thread”。在Java中使用引号时,必须将它们写为“不仅仅是”。将您的字符串更改为“Is Thread \”。 附:如果这个答案对您有帮助,请考虑接受。祝你好运!