Javadoc (b116) lacks @FunctionalInterface on Observer signature

Joseph Darcy joe.darcy at oracle.com
Thu Nov 21 19:02:48 PST 2013


Hi Paul,

On 11/21/2013 2:47 PM, Paul Benedict wrote:
> I have found some more inconsistencies in other types.
>
> These have it:
> * FileFilter
> * FilenameFilter
> * Runnable
>
> These do not:
> * AutoCloseable
> * Comparable
> * Iterable
> * Readable
> * Closeable
> * Flushable
>
> If there are more, I don't know; I just wanted to give an FYI to start the
> investigation.

At least some of these are intentional omissions; see

         JDK-8022658 Revisit FunctionalInterface on some core libs types
         https://bugs.openjdk.java.net/browse/JDK-8022658

http://mail.openjdk.java.net/pipermail/core-libs-dev/2013-October/022416.html

HTH,

-Joe

>
>
> On Thu, Nov 21, 2013 at 4:23 PM, Paul Benedict <pbenedict at apache.org> wrote:
>
>> While reading the Observer javadocs [1], I noticed the message of it being
>> a functional interface yet the annotation is not appearing on the signature:
>>
>> "public interface Observer" without the annotation.
>>
>> Now compare that to javadocs of Comparator:
>> "@FunctionalInterface
>> public interface Comparator<T>"
>>
>> [1] http://download.java.net/jdk8/docs/api/java/util/Observer.html
>>
>> --
>> Cheers,
>> Paul
>>
>
>



More information about the lambda-dev mailing list