Chris Senior wrote:
SearchPattern superPattern = SearchPattern.createPattern(aType,
IJavaSearchConstants.IMPLEMENTORS);
Where aType is an IType for interface A.
After a bit more testing it seemed the search only works with interfaces?
If the aType is an abstract class it does not return classes that
"extend" that class. But the documentation for the IMPLEMENTORS flag
states that:
"The search result is a type that implements an interface or extends a
class. Used in conjunction with either TYPE or CLASS or INTERFACE, it
will respectively search for any type implementing/extending a type, or
rather exclusively search for classes implementing/extending the type,
or interfaces extending the type."
Which is what confused me ... it seems I have a choice of TYPE, CLASS or
INTERFACE? I thought it might deduce CLASS or INTERFACE from the IType I
passed in, and only do a TYPE search if I specify that.
- Chris