< prev index next >

src/java.compiler/share/classes/javax/lang/model/util/ElementKindVisitor6.java

Print this page

        

*** 152,161 **** --- 152,164 ---- return visitTypeAsEnum(e, p); case INTERFACE: return visitTypeAsInterface(e, p); + case RECORD: + return visitTypeAsRecord(e, p); + default: throw new AssertionError("Bad kind " + k + " for TypeElement" + e); } }
*** 210,225 **** public R visitTypeAsInterface(TypeElement e, P p) { return defaultAction(e, p); } /** * Visits a variable element * * @implSpec This implementation dispatches to the visit method for * the specific {@linkplain ElementKind kind} of variable, {@code * ENUM_CONSTANT}, {@code EXCEPTION_PARAMETER}, {@code FIELD}, ! * {@code LOCAL_VARIABLE}, {@code PARAMETER}, or {@code RESOURCE_VARIABLE}. * * @param e {@inheritDoc} * @param p {@inheritDoc} * @return the result of the kind-specific visit method */ --- 213,244 ---- public R visitTypeAsInterface(TypeElement e, P p) { return defaultAction(e, p); } /** + * Visits a {@code RECORD} type element. + * + * @implSpec This implementation calls {@code visitUnknown}. + *. + * @param e the element to visit + * @param p a visitor-specified parameter + * @return the result of {@code visitUnknown} + * + * @since amber + */ + public R visitTypeAsRecord(TypeElement e, P p) { + return visitUnknown(e, p); + } + + /** * Visits a variable element * * @implSpec This implementation dispatches to the visit method for * the specific {@linkplain ElementKind kind} of variable, {@code * ENUM_CONSTANT}, {@code EXCEPTION_PARAMETER}, {@code FIELD}, ! * {@code LOCAL_VARIABLE}, {@code PARAMETER}, {@code RESOURCE_VARIABLE}, ! * or {@code STATE_COMPONENT}. * * @param e {@inheritDoc} * @param p {@inheritDoc} * @return the result of the kind-specific visit method */
*** 243,252 **** --- 262,274 ---- return visitVariableAsParameter(e, p); case RESOURCE_VARIABLE: return visitVariableAsResourceVariable(e, p); + case STATE_COMPONENT: + return visitVariableAsStateComponent(e, p); + default: throw new AssertionError("Bad kind " + k + " for VariableElement" + e); } }
*** 329,338 **** --- 351,375 ---- public R visitVariableAsResourceVariable(VariableElement e, P p) { return visitUnknown(e, p); } /** + * Visits a {@code STATE_COMPONENT} variable element. + * + * @implSpec This implementation calls {@code visitUnknown}. + * + * @param e the element to visit + * @param p a visitor-specified parameter + * @return the result of {@code visitUnknown} + * + * @since amber + */ + public R visitVariableAsStateComponent(VariableElement e, P p) { + return visitUnknown(e, p); + } + + /** * {@inheritDoc} * * @implSpec This implementation dispatches to the visit method * for the specific {@linkplain ElementKind kind} of executable, * {@code CONSTRUCTOR}, {@code INSTANCE_INIT}, {@code METHOD}, or
< prev index next >