Static Implementation
import com.this.class.ImportedClass;
getElementsAnnotatedWith(ImportedClass.class)
the above method call works when I use import, but when I want to load the same class dynamically
ImportedClass Class = Class.forName("com.this.class.ImportedClass");
getElementsAnnotatedWith(importedClass.class)
When I pass the .class file it wont take the parameter.
Aucun commentaire:
Enregistrer un commentaire