[
https://issues.jboss.org/browse/JBIDE-17877?page=com.atlassian.jira.plugi...
]
Xavier Coulon resolved JBIDE-17877.
-----------------------------------
Resolution: Won't Fix
[~dgolovin],
thanks for the reply. There is no exception at the JAX-RS tooling level when processing
the code sample, and there's an endpoint for the Java method in the Project explorer,
as expected.
So, I'm closing this issue.
Classe with unbounded type parameter triggers "TypeParameter
cannot be cast to IType" exceptions
------------------------------------------------------------------------------------------------
Key: JBIDE-17877
URL:
https://issues.jboss.org/browse/JBIDE-17877
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: webservices
Affects Versions: 4.2.0.Beta3
Reporter: Denis Golovin
Assignee: Xavier Coulon
Fix For: 4.2.0.CR1
Exception below was fixed by checking instance of target obect before casting to IType
see JBIDE-17716 and skipping the rest of the code.
Do we need to do something extra in this case?
{code}
org.jboss.tools.common
Error
Mon Jun 30 12:28:44 CEST 2014
org.eclipse.jdt.internal.core.TypeParameter cannot be cast to org.eclipse.jdt.core.IType
org.jboss.tools.common.validation.JBTValidationException:
org.eclipse.jdt.internal.core.TypeParameter cannot be cast to org.eclipse.jdt.core.IType
at
org.jboss.tools.common.validation.AsYouTypeValidatorManager.validate(AsYouTypeValidatorManager.java:187)
at
org.jboss.tools.common.validation.AsYouTypeValidatorManager.validateString(AsYouTypeValidatorManager.java:205)
at
org.jboss.tools.common.validation.AsYouTypeValidatorManager.validateString(AsYouTypeValidatorManager.java:200)
at
org.jboss.tools.common.validation.java.JavaDirtyRegionProcessor.endProcessing(JavaDirtyRegionProcessor.java:498)
at
org.eclipse.wst.sse.ui.internal.reconcile.DirtyRegionProcessor$BackgroundThread.run(DirtyRegionProcessor.java:697)
Caused by: java.lang.ClassCastException: org.eclipse.jdt.internal.core.TypeParameter
cannot be cast to org.eclipse.jdt.core.IType
at org.jboss.tools.ws.jaxrs.core.jdt.SourceType.from(SourceType.java:79)
at org.jboss.tools.ws.jaxrs.core.jdt.JdtUtils.getReturnType(JdtUtils.java:1143)
at
org.jboss.tools.ws.jaxrs.core.jdt.JdtUtils.resolveMethodSignature(JdtUtils.java:1067)
at
org.jboss.tools.ws.jaxrs.core.jdt.JdtUtils.resolveMethodSignatures(JdtUtils.java:1037)
at
org.jboss.tools.ws.jaxrs.core.jdt.CompilationUnitsRepository.recordAST(CompilationUnitsRepository.java:112)
at
org.jboss.tools.ws.jaxrs.core.jdt.CompilationUnitsRepository.getAST(CompilationUnitsRepository.java:76)
at
org.jboss.tools.ws.jaxrs.ui.internal.validation.JaxrsMetamodelValidator.validate(JaxrsMetamodelValidator.java:413)
at
org.jboss.tools.common.validation.AsYouTypeValidatorManager.validate(AsYouTypeValidatorManager.java:183)
... 4 more
{code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)