dev@glassfish.java.net

[_at_V] Getting the ClassFile reference in rule classes in Verifier

From: Seema Richard <Seema.Richard_at_ust-global.com>
Date: Sat, 10 May 2008 21:05:19 +0530

Sahoo,

This is regarding writing rules in the verifier to detect the usage of non-standard annotations. I have made annotations a part of the model that represents the information contained in a Java .class file. The getAnnotations() method in ClassFile can be used to get the annotation information. However, this model is not available within a rule class. The model reference is available only the Closure-related classes at present. I think we can access these classes in the rules.

ClosureCompiler closureCompiler=getVerifierContext().getClosureCompiler();

But using these classes to get to the model doesn't seem to be the right way.

Could you please share your thoughts on this?

Thanks,
Seema