Eclipse启动不了 java.lang.NullPointerException

今天运行自己本本里的Eclipse,居然看到下面图片

Eclipse启动不了 java.lang.NullPointerException_第1张图片

运行几秒后,就自动消失了,没有任何的异常弹出。

接着,通过cmd来启动:

1,定位到Eclipse的安装目录下,执行eclipsec.exe文件

2,看到如下的异常信息

java.lang.NullPointerException 
         at org.eclipse.core.internal.runtime.InternalPlatform.getLog(InternalPla 
tform.java:354) 
         at org.eclipse.core.runtime.Plugin.getLog(Plugin.java:291) 
         at org.eclipse.ui.internal.WorkbenchPlugin.log(WorkbenchPlugin.java:830) 
  
         at org.eclipse.ui.statushandlers.StatusManager.logError(StatusManager.ja 
va:285) 
         at org.eclipse.ui.statushandlers.StatusManager.handle(StatusManager.java 
:200) 
         at org.eclipse.ui.statushandlers.StatusManager.handle(StatusManager.java 
:231) 
         at org.eclipse.ui.statushandlers.StatusManager$StatusManagerLogListener. 
logging(StatusManager.java:305) 
         at org.eclipse.core.internal.runtime.RuntimeLog.logToListeners(RuntimeLo 
g.java:160) 
         at org.eclipse.core.internal.runtime.PlatformLogWriter.logged(PlatformLo 
gWriter.java:100) 
         at org.eclipse.equinox.log.internal.ExtendedLogReaderServiceFactory.safe 
Logged(ExtendedLogReaderServiceFactory.java:86) 
         at org.eclipse.equinox.log.internal.ExtendedLogReaderServiceFactory.logP 
rivileged(ExtendedLogReaderServiceFactory.java:205) 
         at org.eclipse.equinox.log.internal.ExtendedLogReaderServiceFactory.log( 
ExtendedLogReaderServiceFactory.java:178) 
         at org.eclipse.equinox.log.internal.ExtendedLogServiceFactory.log(Extend 
edLogServiceFactory.java:65) 
         at org.eclipse.equinox.log.internal.ExtendedLogServiceImpl.log(ExtendedL 
ogServiceImpl.java:87) 
         at org.eclipse.equinox.log.internal.LoggerImpl.log(LoggerImpl.java:54) 
         at org.eclipse.core.internal.runtime.PlatformLogWriter.logging(PlatformL 
ogWriter.java:43) 
         at org.eclipse.core.internal.runtime.RuntimeLog.log(RuntimeLog.java:96) 
         at org.eclipse.core.internal.jobs.JobManager.doShutdown(JobManager.java: 
606) 
         at org.eclipse.core.internal.jobs.JobManager.shutdown(JobManager.java:25 
2) 
         at org.eclipse.core.internal.jobs.JobActivator.stop(JobActivator.java:55 

         at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(Bund 
leContextImpl.java:771) 
         at java.security.AccessController.doPrivileged(Native Method) 
         at org.eclipse.osgi.framework.internal.core.BundleContextImpl.stop(Bundl 
eContextImpl.java:764) 
         at org.eclipse.osgi.framework.internal.core.BundleHost.stopWorker(Bundle 
Host.java:510) 
         at org.eclipse.osgi.framework.internal.core.AbstractBundle.suspend(Abstr 
actBundle.java:566) 
         at org.eclipse.osgi.framework.internal.core.Framework.suspendBundle(Fram 
ework.java:1206) 
         at org.eclipse.osgi.framework.internal.core.StartLevelManager.decFWSL(St 
artLevelManager.java:592) 
         at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStart 
Level(StartLevelManager.java:257) 
         at org.eclipse.osgi.framework.internal.core.StartLevelManager.shutdown(S 
tartLevelManager.java:215) 
         at org.eclipse.osgi.framework.internal.core.InternalSystemBundle.suspend 
(InternalSystemBundle.java:284) 
         at org.eclipse.osgi.framework.internal.core.Framework.shutdown(Framework 
.java:692) 
         at org.eclipse.osgi.framework.internal.core.Framework.close(Framework.ja 
va:600) 
         at org.eclipse.core.runtime.adaptor.EclipseStarter.shutdown(EclipseStart 
er.java:400) 
         at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.ja 
va:200) 
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. 
java:57) 
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces 
sorImpl.java:43) 
         at java.lang.reflect.Method.invoke(Method.java:601) 
         at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636) 
         at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591) 
         at org.eclipse.equinox.launcher.Main.run(Main.java:1450) 
Job found still running after platform shutdown.  Jobs should be canceled by the 
  plugin that scheduled them during shutdown: org.eclipse.core.internal.refresh.R 
efreshJob 
java.lang.NullPointerException 
         at org.eclipse.core.internal.runtime.InternalPlatform.getLog(InternalPla 
tform.java:354) 
         at org.eclipse.core.runtime.Plugin.getLog(Plugin.java:291) 
         at org.eclipse.ui.internal.WorkbenchPlugin.log(WorkbenchPlugin.java:830) 
  
         at org.eclipse.ui.statushandlers.StatusManager.logError(StatusManager.ja 
va:285) 
         at org.eclipse.ui.statushandlers.StatusManager.handle(StatusManager.java 
:200) 
         at org.eclipse.ui.statushandlers.StatusManager.handle(StatusManager.java 
:231) 
         at org.eclipse.ui.statushandlers.StatusManager$StatusManagerLogListener. 
logging(StatusManager.java:305) 
         at org.eclipse.core.internal.runtime.RuntimeLog.logToListeners(RuntimeLo 
g.java:160) 
         at org.eclipse.core.internal.runtime.PlatformLogWriter.logged(PlatformLo 
gWriter.java:100) 
         at org.eclipse.equinox.log.internal.ExtendedLogReaderServiceFactory.safe 
Logged(ExtendedLogReaderServiceFactory.java:86) 
         at org.eclipse.equinox.log.internal.ExtendedLogReaderServiceFactory.logP 
rivileged(ExtendedLogReaderServiceFactory.java:205) 
         at org.eclipse.equinox.log.internal.ExtendedLogReaderServiceFactory.log( 
ExtendedLogReaderServiceFactory.java:178) 
         at org.eclipse.equinox.log.internal.ExtendedLogServiceFactory.log(Extend 
edLogServiceFactory.java:65) 
         at org.eclipse.equinox.log.internal.ExtendedLogServiceImpl.log(ExtendedL 
ogServiceImpl.java:87) 
         at org.eclipse.equinox.log.internal.LoggerImpl.log(LoggerImpl.java:54) 
         at org.eclipse.core.internal.runtime.PlatformLogWriter.logging(PlatformL 
ogWriter.java:43) 
         at org.eclipse.core.internal.runtime.RuntimeLog.log(RuntimeLog.java:96) 
         at org.eclipse.core.internal.jobs.JobManager.doShutdown(JobManager.java: 
606) 
         at org.eclipse.core.internal.jobs.JobManager.shutdown(JobManager.java:25 
2) 
         at org.eclipse.core.internal.jobs.JobActivator.stop(JobActivator.java:55 

         at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(Bund 
leContextImpl.java:771) 
         at java.security.AccessController.doPrivileged(Native Method) 
         at org.eclipse.osgi.framework.internal.core.BundleContextImpl.stop(Bundl 
eContextImpl.java:764) 
         at org.eclipse.osgi.framework.internal.core.BundleHost.stopWorker(Bundle 
Host.java:510) 
         at org.eclipse.osgi.framework.internal.core.AbstractBundle.suspend(Abstr 
actBundle.java:566) 
         at org.eclipse.osgi.framework.internal.core.Framework.suspendBundle(Fram 
ework.java:1206) 
         at org.eclipse.osgi.framework.internal.core.StartLevelManager.decFWSL(St 
artLevelManager.java:592) 
         at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStart 
Level(StartLevelManager.java:257) 
         at org.eclipse.osgi.framework.internal.core.StartLevelManager.shutdown(S 
tartLevelManager.java:215) 
         at org.eclipse.osgi.framework.internal.core.InternalSystemBundle.suspend 
(InternalSystemBundle.java:284) 
         at org.eclipse.osgi.framework.internal.core.Framework.shutdown(Framework 
.java:692) 
         at org.eclipse.osgi.framework.internal.core.Framework.close(Framework.ja 
va:600) 
         at org.eclipse.core.runtime.adaptor.EclipseStarter.shutdown(EclipseStart 
er.java:400) 
         at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.ja 
va:200) 
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. 
java:57) 
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces 
sorImpl.java:43) 
         at java.lang.reflect.Method.invoke(Method.java:601) 
         at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636) 
         at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591) 
         at org.eclipse.equinox.launcher.Main.run(Main.java:1450) 
Job found still running after platform shutdown.  Jobs should be canceled by the 
  plugin that scheduled them during shutdown: org.eclipse.core.internal.refresh.R 
efreshJob 

于是,我干脆就删掉 workspace 里的 .metadata 目录,重建工程

这样,eclipse又能启动了。不知道有没有那个大侠知道这是什么原因。

你可能感兴趣的:(java)