46 * methods with names beginning with {@code "visit"}.
47 *
48 * <p>When such a new visit method is added, the default
49 * implementation in this class will be to call the {@link
50 * #visitUnknown visitUnknown} method. A new abstract element visitor
51 * class will also be introduced to correspond to the new language
52 * level; this visitor will have different default behavior for the
53 * visit method in question. When the new visitor is introduced, all
54 * or portions of this visitor may be deprecated.
55 *
56 * @param <R> the return type of this visitor's methods. Use {@link
57 * Void} for visitors that do not need to return results.
58 * @param <P> the type of the additional parameter to this visitor's
59 * methods. Use {@code Void} for visitors that do not need an
60 * additional parameter.
61 *
62 * @see AbstractElementVisitor6
63 * @see AbstractElementVisitor7
64 * @see AbstractElementVisitor8
65 * @since 9
66 */
67 @SupportedSourceVersion(RELEASE_9)
68 public abstract class AbstractElementVisitor9<R, P> extends AbstractElementVisitor8<R, P> {
69 /**
70 * Constructor for concrete subclasses to call.
71 */
72 protected AbstractElementVisitor9(){
73 super();
74 }
75
76 /**
77 * Visits a {@code ModuleElement} in a manner defined by a
78 * subclass.
79 *
80 * @param t {@inheritDoc}
81 * @param p {@inheritDoc}
82 * @return the result of the visit as defined by a subclass
83 */
84 @Override
85 public abstract R visitModule(ModuleElement t, P p);
|
46 * methods with names beginning with {@code "visit"}.
47 *
48 * <p>When such a new visit method is added, the default
49 * implementation in this class will be to call the {@link
50 * #visitUnknown visitUnknown} method. A new abstract element visitor
51 * class will also be introduced to correspond to the new language
52 * level; this visitor will have different default behavior for the
53 * visit method in question. When the new visitor is introduced, all
54 * or portions of this visitor may be deprecated.
55 *
56 * @param <R> the return type of this visitor's methods. Use {@link
57 * Void} for visitors that do not need to return results.
58 * @param <P> the type of the additional parameter to this visitor's
59 * methods. Use {@code Void} for visitors that do not need an
60 * additional parameter.
61 *
62 * @see AbstractElementVisitor6
63 * @see AbstractElementVisitor7
64 * @see AbstractElementVisitor8
65 * @since 9
66 * @spec JPMS
67 */
68 @SupportedSourceVersion(RELEASE_9)
69 public abstract class AbstractElementVisitor9<R, P> extends AbstractElementVisitor8<R, P> {
70 /**
71 * Constructor for concrete subclasses to call.
72 */
73 protected AbstractElementVisitor9(){
74 super();
75 }
76
77 /**
78 * Visits a {@code ModuleElement} in a manner defined by a
79 * subclass.
80 *
81 * @param t {@inheritDoc}
82 * @param p {@inheritDoc}
83 * @return the result of the visit as defined by a subclass
84 */
85 @Override
86 public abstract R visitModule(ModuleElement t, P p);
|