Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Why is the @Deprecated annotation tracked by SignatureTest tool, but its ancestor the @deprecated Javadoc tag is not?

0
Posted

Why is the @Deprecated annotation tracked by SignatureTest tool, but its ancestor the @deprecated Javadoc tag is not?

0

The @Deprecated annotation and @deprecated Javadoc comment are not the same. The most important difference to SignatureTest tool is that the @Deprecated annotation is specified by the Java Language Specification, but the Javadoc tag is not. According to the following section of Sun’s guide How and When To Deprecate APIs the @Deprecated annotation is mandatory and @deprecated Javadoc tag is optional: How to Deprecate Starting with Java SE 5.0, you deprecate a class, method, or field by using the @Deprecated annotation. Additionally, you can use the @deprecated Javadoc tag tell developers what to use instead. Using the annotation causes the Java language compiler to generate warnings when the deprecated class, method, or field is used. The compiler suppresses deprecation warnings if a deprecated compilation unit uses a deprecated class, method, or field. This enables you to build legacy APIs without generating warnings. You are strongly encouraged to use the Javadoc @deprecated tag with

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123