# HG changeset patch # User darcy # Date 1467253480 25200 # Node ID 3a9d6e8c6fde3a1fb87b953e44b85594e5fd99a2 # Parent 8bf5fe72ca887939b79709bcb32f4557e51022c7 8160506: Use @implSpec tags in javax.lang.model.util Reviewed-by: jjg diff -r 8bf5fe72ca88 -r 3a9d6e8c6fde langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractAnnotationValueVisitor6.java --- a/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractAnnotationValueVisitor6.java Tue Jun 28 13:33:04 2016 +0200 +++ b/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractAnnotationValueVisitor6.java Wed Jun 29 19:24:40 2016 -0700 @@ -113,7 +113,7 @@ /** * {@inheritDoc} * - *

The default implementation of this method in {@code + * @implSpec The default implementation of this method in {@code * AbstractAnnotationValueVisitor6} will always throw {@code * UnknownAnnotationValueException}. This behavior is not * required of a subclass. @@ -121,6 +121,7 @@ * @param av {@inheritDoc} * @param p {@inheritDoc} */ + @Override public R visitUnknown(AnnotationValue av, P p) { throw new UnknownAnnotationValueException(av, p); } diff -r 8bf5fe72ca88 -r 3a9d6e8c6fde langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractElementVisitor6.java --- a/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractElementVisitor6.java Tue Jun 28 13:33:04 2016 +0200 +++ b/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractElementVisitor6.java Wed Jun 29 19:24:40 2016 -0700 @@ -118,25 +118,28 @@ /** * {@inheritDoc} * - *

The default implementation of this method in + * @implSpec The default implementation of this method in * {@code AbstractElementVisitor6} will always throw * {@code UnknownElementException}. * This behavior is not required of a subclass. * - * @param e the element to visit - * @param p a visitor-specified parameter + * @param e {@inheritDoc} + * @param p {@inheritDoc} * @return a visitor-specified result * @throws UnknownElementException * a visitor implementation may optionally throw this exception */ + @Override public R visitUnknown(Element e, P p) { throw new UnknownElementException(e, p); } /** - * Visits a {@code ModuleElement} by calling {@code + * {@inheritDoc} + * + * @implSpec Visits a {@code ModuleElement} by calling {@code * visitUnknown}. - + * * @param e {@inheritDoc} * @param p {@inheritDoc} * @return the result of {@code visitUnknown} diff -r 8bf5fe72ca88 -r 3a9d6e8c6fde langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor6.java --- a/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor6.java Tue Jun 28 13:33:04 2016 +0200 +++ b/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor6.java Wed Jun 29 19:24:40 2016 -0700 @@ -114,9 +114,11 @@ } /** - * Visits a {@code UnionType} element by calling {@code + * {@inheritDoc} + * + * @implSpec Visits a {@code UnionType} element by calling {@code * visitUnknown}. - + * * @param t {@inheritDoc} * @param p {@inheritDoc} * @return the result of {@code visitUnknown} @@ -128,15 +130,18 @@ } /** - * Visits an {@code IntersectionType} element by calling {@code + * {@inheritDoc} + * + * @implSpec Visits an {@code IntersectionType} element by calling {@code * visitUnknown}. - + * * @param t {@inheritDoc} * @param p {@inheritDoc} * @return the result of {@code visitUnknown} * * @since 1.8 */ + @Override public R visitIntersection(IntersectionType t, P p) { return visitUnknown(t, p); } @@ -144,16 +149,18 @@ /** * {@inheritDoc} * - *

The default implementation of this method in {@code + * @implSpec The default implementation of this method in {@code * AbstractTypeVisitor6} will always throw {@code * UnknownTypeException}. This behavior is not required of a * subclass. * - * @param t the type to visit + * @param t {@inheritDoc} + * @param p {@inheritDoc} * @return a visitor-specified result * @throws UnknownTypeException * a visitor implementation may optionally throw this exception */ + @Override public R visitUnknown(TypeMirror t, P p) { throw new UnknownTypeException(t, p); } diff -r 8bf5fe72ca88 -r 3a9d6e8c6fde langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor7.java --- a/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor7.java Tue Jun 28 13:33:04 2016 +0200 +++ b/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor7.java Wed Jun 29 19:24:40 2016 -0700 @@ -89,5 +89,6 @@ * @param p {@inheritDoc} * @return the result of the visit as defined by a subclass */ + @Override public abstract R visitUnion(UnionType t, P p); } diff -r 8bf5fe72ca88 -r 3a9d6e8c6fde langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor8.java --- a/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor8.java Tue Jun 28 13:33:04 2016 +0200 +++ b/langtools/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor8.java Wed Jun 29 19:24:40 2016 -0700 @@ -88,5 +88,6 @@ * @param p {@inheritDoc} * @return the result of the visit as defined by a subclass */ + @Override public abstract R visitIntersection(IntersectionType t, P p); }