开发者

How can I retrieve the package name of the object using eclipse development JDT API?

I need to get the source package of the any object declared in the class. This object may be declared as a class variable or met开发者_运维技巧hods local variable.

I can able to find that for class object variable using IFields API.

For example, if the variable is of type List -> I need the result as java.util.List.

Kindly give your ideas.

Thanks in advance, Easwar


The IProject interface extends the IContainer which has several findMember methods. You get all IResource(Java files) and get package name ....

Note: IResource are resources other then Java files also

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜