Review request for present, directly present, etc. in core reflection javadoc
elena votchennikova
elena.votchennikova at oracle.com
Thu Jul 11 04:13:55 PDT 2013
Hi Joe,
specifications for methods getDeclaredAnnotation(Class),
getDeclaredAnnotations(), getDeclaredAnnotationsByType(Class) is valid
and there are no contradiction (formally).
But the following classes
- j.l.Package
- j.l.r.AccessibleObject
(re: j.l.r.Field, j.l.r.Executable, j.l.r.Method, j.l.r.Constructor)
- j.l.r.Parameter
can have only directly present annotation. So, I think this is strange
to describe in the specification cases for inherited annotations for
these classes, because it could mislead readers.
Elena
On 10.07.2013 23:11, Joe Darcy wrote:
> On 07/10/2013 11:29 AM, Alex Buckley wrote:
>> Elena Votchennikova pointed out in a comment of JDK-8010679 that
>> classes which implement AnnotatedElement contain method
>> specifications copied from AnnotatedElement. I believe the following
>> classes need to have their method specifications updated:
>>
>> - j.l.Class
>> - j.l.Package
>> - j.l.r.AccessibleObject
>> (re: j.l.r.Field, j.l.r.Executable, j.l.r.Method, j.l.r.Constructor)
>> - j.l.r.Parameter
>
> The specifications on the implementation classes should generally just
> be @inheritdoc'ed (meaning no explicit update should be needed in
> those files), but I'll double check.
>
> -Joe
>
More information about the enhanced-metadata-spec-discuss
mailing list