Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Watson2010-04-22 10:48:28 -0400
committerThomas Watson2010-04-22 10:48:28 -0400
commit24d1a195da2cb81c5c4b8ea48f9aaf5a84bc9863 (patch)
treea83fdbf9fb68217042c0b9bbf25a9ade6150840a /bundles/org.eclipse.osgi
parenta28a055573617342cae001e733c53ab0d5c6ad81 (diff)
downloadrt.equinox.framework-24d1a195da2cb81c5c4b8ea48f9aaf5a84bc9863.tar.gz
rt.equinox.framework-24d1a195da2cb81c5c4b8ea48f9aaf5a84bc9863.tar.xz
rt.equinox.framework-24d1a195da2cb81c5c4b8ea48f9aaf5a84bc9863.zip
Bug 310099 Unclear exception message when a bundle cannot be resolvedv20100422
Diffstat (limited to 'bundles/org.eclipse.osgi')
-rw-r--r--bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/AbstractBundle.java4
-rw-r--r--bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/framework/internal/core/ExternalMessages.properties2
2 files changed, 3 insertions, 3 deletions
diff --git a/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/AbstractBundle.java b/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/AbstractBundle.java
index 93617cd80..1e10d791e 100644
--- a/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/AbstractBundle.java
+++ b/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/AbstractBundle.java
@@ -1294,7 +1294,7 @@ public abstract class AbstractBundle implements Bundle, Comparable, KeyedElement
public BundleException getResolutionFailureException() {
BundleDescription bundleDescription = getBundleDescription();
if (bundleDescription == null)
- return new BundleException(Msg.BUNDLE_UNRESOLVED_EXCEPTION, BundleException.RESOLVE_ERROR);
+ return new BundleException(NLS.bind(Msg.BUNDLE_UNRESOLVED_EXCEPTION, this.toString()), BundleException.RESOLVE_ERROR);
// just a sanity check - this would be an inconsistency between the framework and the state
if (bundleDescription.isResolved())
return new BundleException(Msg.BUNDLE_UNRESOLVED_STATE_CONFLICT, BundleException.RESOLVE_ERROR);
@@ -1304,7 +1304,7 @@ public abstract class AbstractBundle implements Bundle, Comparable, KeyedElement
private BundleException getResolverError(BundleDescription bundleDesc) {
ResolverError[] errors = framework.adaptor.getState().getResolverErrors(bundleDesc);
if (errors == null || errors.length == 0)
- return new BundleException(Msg.BUNDLE_UNRESOLVED_EXCEPTION, BundleException.RESOLVE_ERROR);
+ return new BundleException(NLS.bind(Msg.BUNDLE_UNRESOLVED_EXCEPTION, this.toString()), BundleException.RESOLVE_ERROR);
StringBuffer message = new StringBuffer();
int errorType = BundleException.RESOLVE_ERROR;
for (int i = 0; i < errors.length; i++) {
diff --git a/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/framework/internal/core/ExternalMessages.properties b/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/framework/internal/core/ExternalMessages.properties
index b44e2b4b1..1c73f44e1 100644
--- a/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/framework/internal/core/ExternalMessages.properties
+++ b/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/framework/internal/core/ExternalMessages.properties
@@ -25,7 +25,7 @@ BUNDLE_STATE_CHANGE_EXCEPTION=State change in progress for bundle \"{0}\" by thr
BUNDLE_REFRESH_FAILURE=PackageAdmin.refreshPackages failed to complete
BUNDLE_ACTIVATOR_EXCEPTION=Exception in {0}.{1}() of bundle {2}.
BUNDLE_INVALID_ACTIVATOR_EXCEPTION=The activator {0} for bundle {1} is invalid
-BUNDLE_UNRESOLVED_EXCEPTION=The bundle could not be resolved
+BUNDLE_UNRESOLVED_EXCEPTION=The bundle \"{0}\" could not be resolved
BUNDLE_UNRESOLVED_STATE_CONFLICT=The state indicates the bundle is resolved
BUNDLE_UNRESOLVED_UNSATISFIED_CONSTRAINT_EXCEPTION=The bundle \"{0}\" could not be resolved. Reason: {1}
BUNDLE_SYSTEMBUNDLE_UNINSTALL_EXCEPTION=The System Bundle cannot be uninstalled

Back to the top