gpt4 book ai didi

java - org.osgi.framework.BundleException :The Activator . .for bundle .. 无效

转载 作者:行者123 更新时间:2023-11-29 05:47:19 25 4
gpt4 key购买 nike

这个Bundle异常是不是因为一次又一次的改变工作空间导致的?我以前正常运行的项目现在在运行时出现此异常。请帮帮我。我已经被这个问题困扰了 2 天。

      Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Project
Bundle-SymbolicName: com.spundhan.eboard.project; singleton:=true
Bundle-Version: 1.0.0.qualifier
Bundle-Activator: com.spundhan.eboard.project.Activator
Bundle-Vendor: SPUNDHAN
Require-Bundle: org.eclipse.emf;bundle-version="2.6.0",
org.eclipse.ui.console;bundle-version="3.5.100",
org.jdom;bundle-version="1.1.1",
org.eclipse.ui.navigator;bundle-version="3.5.101",
org.eclipse.ui.navigator.resources;bundle-version="3.4.300",
org.eclipse.ui.views.log;bundle-version="1.0.200",
org.eclipse.ui.ide;bundle-version="3.7.0",
org.eclipse.core.resources;bundle-version="3.7.101",
org.eclipse.gef;bundle-version="3.7.2",
org.eclipse.emf.ecore;bundle-version="2.7.0",
org.eclipse.ui.views;bundle-version="3.6.0",
org.eclipse.help;bundle-version="3.5.100",
org.eclipse.help.ui;bundle-version="3.5.101",
org.eclipse.ui.forms;bundle-version="3.5.101",
org.eclipse.ui.intro.universal;bundle-version="3.2.500",
org.eclipse.help.webapp;bundle-version="3.6.1",
org.eclipse.ui.intro;bundle-version="3.4.100",
org.eclipse.cdt.ui;bundle-version="5.2.2";resolution:=optional,
com.spundhan.eboard.code;bundle-version="1.0.0",
com.spundhan.eboard.emf;bundle-version="1.0.0",
com.spundhan.eboard.gef;bundle-version="1.0.0"
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-ActivationPolicy: lazy
Import-Package: com.spundhan.eboard.gef.components.model,
com.spundhan.eboard.gef.model,
com.spundhan.eboard.gef.part,
com.spundhan.eboard.model,
org.eclipse.core.resources,
org.eclipse.jface.text,
org.eclipse.ui.console
Bundle-ClassPath: .,
libs/com.spundhan.licensing-1.0.0.jar,
libs/log4j-1.2.15.jar,
libs/RXTXcomm.jar,
libs/com.spundhan.eboard.db-1.0.0.jar,
.,
libs/bcpg-jdk15-143.jar,
libs/bcprov-jdk15-143.jar

激活剂:

package com.spundhan.eboard.project;

import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.ui.plugin.AbstractUIPlugin;
import org.osgi.framework.BundleContext;

/**
* The activator class controls the plug-in life cycle
*/
public class Activator extends AbstractUIPlugin {

// The plug-in ID
public static final String PLUGIN_ID = "com.spundhan.eboard.project"; //$NON-NLS-1$

// The shared instance
private static Activator plugin;

/**
* The constructor
*/
public Activator() {
}

/*
* (non-Javadoc)
* @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
*/
@Override
public void start(BundleContext context) throws Exception {
super.start(context);
plugin = this;
}

/*
* (non-Javadoc)
* @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
*/
@Override
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
}

/**
* Returns the shared instance
*
* @return the shared instance
*/
public static Activator getDefault() {
return plugin;
}

/**
* Returns an image descriptor for the image file at the given
* plug-in relative path
*
* @param path the path
* @return the image descriptor
*/
public static ImageDescriptor getImageDescriptor(String path) {
return imageDescriptorFromPlugin(PLUGIN_ID, path);
}
}

最佳答案

这是对我有效的解决方案。每个错误都不同,但让我们看看您是否幸运。

打开 list 并转到“构建”选项卡。在运行配置中,如果没有出现,点击“添加库”,然后写一个点“.”。然后,将 src/ 添加到运行时文件夹。

希望这对您有所帮助。

关于java - org.osgi.framework.BundleException :The Activator . .for bundle .. 无效,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15383567/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com