No, there is no standard annotation specifically for methods that have yet to be implemented.
However, there is a more general annotation in the JDK that marks an API which developers are discouraged from using, and the Java compiler itself can issue warnings when it is used. I am talking about @Deprecated
, which many developers only think of as "announcing removal". However, the relevant articles in the JDK docs (e.g. for Java 7 and Java 9) list several example use cases, only one of them being about removal:
The API is dangerous (for example, the Thread.stop
method).
There is a simple rename (for example, AWT Component.show/hide
replaced by setVisible
).
A newer, better API can be used instead.
The deprecated API is going to be removed.
I think your case "not implemented yet" certainly goes in the same direction as those. Further, if the method would always throw a NotYetImplementedException
, it even fits the example "The API is dangerous".
So all you need to do is the following:
- Add
@Deprecated
to the method
- Add
@deprecated
Javadoc to explain the background
- Configure your build to invoke the compiler with
-Xlint:deprecation
so that it issues warnings.