From 87766a2dc1db0748e723e668b1b1f5881c596355 Mon Sep 17 00:00:00 2001 From: Eugene Zhuravlev Date: Thu, 21 Oct 2010 19:08:42 +0400 Subject: [PATCH] providing better error descriptions (IDEA-60110) --- .../intellij/lang/ant/dom/CustomAntElementsRegistry.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/ant/src/com/intellij/lang/ant/dom/CustomAntElementsRegistry.java b/plugins/ant/src/com/intellij/lang/ant/dom/CustomAntElementsRegistry.java index 8bf4aa8f39b4..71194132edf6 100644 --- a/plugins/ant/src/com/intellij/lang/ant/dom/CustomAntElementsRegistry.java +++ b/plugins/ant/src/com/intellij/lang/ant/dom/CustomAntElementsRegistry.java @@ -283,21 +283,21 @@ public class CustomAntElementsRegistry { clazz = loader.loadClass(classname); } catch (ClassNotFoundException e) { - error = e.getMessage(); + error = "Class not found " + e.getMessage(); if (error == null) { error = ""; } clazz = null; } catch (NoClassDefFoundError e) { - error = e.getMessage(); + error = "Class definition not found " + e.getMessage(); if (error == null) { error = ""; } clazz = null; } catch (UnsupportedClassVersionError e) { - error = e.getMessage(); + error = "Unsupported class version " + e.getMessage(); if (error == null) { error = ""; } @@ -309,7 +309,7 @@ public class CustomAntElementsRegistry { private void addCustomDefinition(@NotNull AntDomNamedElement declaringTag, String customTagName, String nsUri, Class clazz, String error) { final XmlName xmlName = new XmlName(customTagName, nsUri == null? "" : nsUri); if (error != null) { - myErrors.put(xmlName, customTagName); + myErrors.put(xmlName, error); } myCustomElements.put(xmlName, clazz); myDeclarations.put(xmlName, declaringTag);