This discussion is archived
1 Reply Latest reply: Jun 13, 2012 3:59 AM by 800268 RSS

ClassCastException in java.lang.ClassCastException: com.sun.tools.apt.mirro

847418 Newbie
Currently Being Moderated
Hi All,

I am getting the class cast exception from java.lang.ClassCastException:com.sun.tools.apt.mirror..type.ClassTypeImpl class.

Anybody having idea about this?.
Problem encountered during annotation processing;
      [apt] see stacktrace below for more information.
      [apt] java.lang.ClassCastException: com.sun.tools.apt.mirror.type.ClassTyp
eImpl
      [apt]     at com.sun.tools.apt.mirror.declaration.AnnotationMirrorImpl.get
AnnotationType(AnnotationMirrorImpl.java:82)
      [apt]     at com.sun.tools.apt.mirror.apt.AnnotationProcessorEnvironmentIm
pl$CollectingAP$CollectingVisitor.visitDeclaration(AnnotationProcessorEnvironmen
tImpl.java:118)
      [apt]     at com.sun.mirror.util.SimpleDeclarationVisitor.visitMemberDecla
ration(SimpleDeclarationVisitor.java:60)
      [apt]     at com.sun.mirror.util.SimpleDeclarationVisitor.visitTypeDeclara
tion(SimpleDeclarationVisitor.java:70)
      [apt]     at com.sun.mirror.util.SimpleDeclarationVisitor.visitInterfaceDe
claration(SimpleDeclarationVisitor.java:100)
      [apt]     at com.sun.tools.apt.mirror.declaration.InterfaceDeclarationImpl
.accept(InterfaceDeclarationImpl.java:32)
      [apt]     at com.sun.mirror.util.SourceOrderDeclScanner.visitTypeDeclarati
on(SourceOrderDeclScanner.java:148)
      [apt]     at com.sun.mirror.util.DeclarationScanner.visitInterfaceDeclarat
ion(DeclarationScanner.java:150)
      [apt]     at com.sun.tools.apt.mirror.declaration.InterfaceDeclarationImpl
.accept(InterfaceDeclarationImpl.java:32)
      [apt]     at com.sun.tools.apt.mirror.apt.AnnotationProcessorEnvironmentIm
pl$CollectingAP.process(AnnotationProcessorEnvironmentImpl.java:126)
      [apt]     at com.sun.tools.apt.mirror.apt.AnnotationProcessorEnvironmentIm
pl.getDeclarationsAnnotatedWith(AnnotationProcessorEnvironmentImpl.java:100)
      [apt]     at org.apache.beehive.controls.runtime.generator.apt.TwoPhaseAnn
otationProcessor.check(TwoPhaseAnnotationProcessor.java:110)
      [apt]     at org.apache.beehive.controls.runtime.generator.apt.TwoPhaseAnn
otationProcessor.process(TwoPhaseAnnotationProcessor.java:95)
      [apt]     at com.sun.mirror.apt.AnnotationProcessors$CompositeAnnotationPr
ocessor.process(AnnotationProcessors.java:60)
      [apt]     at com.sun.tools.apt.comp.Apt.main(Apt.java:454)
      [apt]     at com.sun.tools.apt.main.JavaCompiler.compile(JavaCompiler.java
:258)
      [apt]     at com.sun.tools.apt.main.Main.compile(Main.java:1102)
      [apt]     at com.sun.tools.apt.main.Main.compile(Main.java:964)
      [apt]     at com.sun.tools.apt.Main.processing(Main.java:95)
      [apt]     at com.sun.tools.apt.Main.process(Main.java:43)
      [apt]     at com.sun.tools.apt.Main.main(Main.java:34)
Thanks,
Vass Lee

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points