In looking thru the code for ResultSpecification_Impl, it seems there
seems to be an inconsistency - unless I (quite possible :-) ) missed
something.
The calls to the containsType(...) method operate in one of 2 ways,
depending on whether or not the result specification has been "compiled"
by calling the compile method.
If the result spec has not been compiled, then containsType(...) returns
true iff the type specified is "equal(...)" to a type in the Result
Specification.
If it has been compiled, then the containsType returns true iff the type
specified is equal to a type *or any of its subtypes* in the Result
Specification. This is because compiling a resultSpecification adds the
subtypes.
Can others confirm this? In actual use within annotators, it may be
that the result spec is always compiled before use (I haven't yet traced
that down).
Should the code and Javadocs be updated to have containsType return true
for subtypes of types in the result spec, always?
-Marshall