[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.platform] Re: How to create a plug-in that uses reflection to find files with annotations ?

I wouldn't use reflection, I would use the JDT instead. Reflection requires the classes to be loaded and you can't load classes from an Eclipse IDE project into Eclipse.

The JDT does annotation processing on the classes in a project without loading them as classes.

However, I don't know the API well enough to tell you how to get the annotations themselves from JDT. Maybe someone else can help out there.

Julien Manankiandrianana wrote:
I have a set of .java files and I wanted to know if there's a way to get the annotated fields using the reflection. Is it possible somehow to create a model of a class from a java file and get every fields, methods, etc. ?

Walter Harley wrote:
I think this is the same question that you already got answered on eclipse.tools.jdt? If not, please clarify.



-- Thanks, Rich Kulp