[英]how can i get the class name?
i have an instance of IMethod type. 我有一个IMethod类型的实例。 i want to get the class name from it. 我想从中获取课程名称。 How can i do that ....help 我该怎么办....帮助
I haven't used the Eclipse API, but it looks like you should call getDeclaringType()
to get an IType
. 我还没有使用Eclipse API,但是看起来您应该调用getDeclaringType()
来获取IType
。 You can then call getElementName()
, getFullyQualifiedName()
etc depending on your requirements. 然后可以根据需要调用getElementName()
, getFullyQualifiedName()
等。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.