do they by annotation mean a comment in a code with // or /* */?
is that annotation is a critical or explanatory commentary or analysis while comments is . ( comment ). Other Comparisons: What's the difference?
Definition of annotation. 1: a note added by way of comment or explanation The bibliography was provided with helpful annotations. 2: the act of annotating something.
Annotations are not included in ‘Javadoc’ comments. The use of @Documented annotation in the code enables tools like Javadoc to process it and include the annotation type information in the generated document. It is designed to be used only as an annotation to another annotation.
It is a marker interface that tells a tool that an annotation is to be documented. Annotations are not included in ‘Javadoc’ comments. The use of @Documented annotation in the code enables tools like Javadoc to process it and include the annotation type information in the generated document.
No, an annotation is not a comment. An annotation is added to a field, class or method, using the syntax @Annotation. One of the best known annotations is @Override, used to signal a method is overriding one from a super class. For example:
public class MyClass {
@Override
public boolean equals(Object other) {
//...
}
}
See http://download.oracle.com/javase/1,5.0/docs/guide/language/annotations.html for more info.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With