ClassCastException thrown during test run in WTP build
diff --git a/bundles/org.eclipse.jst.ws.jaxws.dom.runtime/src/org/eclipse/jst/ws/jaxws/dom/runtime/registry/WsDOMRuntimeRegistry.java b/bundles/org.eclipse.jst.ws.jaxws.dom.runtime/src/org/eclipse/jst/ws/jaxws/dom/runtime/registry/WsDOMRuntimeRegistry.java
index f3fc21e..7f5f48a 100755
--- a/bundles/org.eclipse.jst.ws.jaxws.dom.runtime/src/org/eclipse/jst/ws/jaxws/dom/runtime/registry/WsDOMRuntimeRegistry.java
+++ b/bundles/org.eclipse.jst.ws.jaxws.dom.runtime/src/org/eclipse/jst/ws/jaxws/dom/runtime/registry/WsDOMRuntimeRegistry.java
@@ -89,7 +89,14 @@
{
try
{
- return (IWsDOMRuntimeExtension) el.createExecutableExtension(XP_IMPLEMENTATION_ELEMENT_CLASS_ATTR);
+ //Classcast exception thrown during WTP build
+ Object impl = el.createExecutableExtension(XP_IMPLEMENTATION_ELEMENT_CLASS_ATTR);
+ if (impl instanceof IWsDOMRuntimeExtension) {
+ return (IWsDOMRuntimeExtension) impl;
+ } else {
+ return null;
+ }
+// return (IWsDOMRuntimeExtension) el.createExecutableExtension(XP_IMPLEMENTATION_ELEMENT_CLASS_ATTR);
}
catch (final CoreException e)
{
@@ -97,11 +104,11 @@
return null;
}
- catch (final ClassCastException e)
- {
- logger().logError("Implementation class does not implement proper interface", e); //$NON-NLS-1$
- return null;
- }
+// catch (final ClassCastException e)
+// {
+// logger().logError("Implementation class does not implement proper interface", e); //$NON-NLS-1$
+// return null;
+// }
}
}