net.sourceforge.pmd.lang.java.ast.ASTImplicitClassDeclaration Maven / Gradle / Ivy
The newest version!
/*
* BSD-style license; for more info see http://pmd.sourceforge.net/license.html
*/
package net.sourceforge.pmd.lang.java.ast;
import org.checkerframework.checker.nullness.qual.NonNull;
import net.sourceforge.pmd.annotation.Experimental;
/**
*
*
* ImplicitClassDeclaration ::= {@linkplain ASTClassBody ClassBody}
*
* ClassBody ::= {@linkplain ASTFieldDeclaration FieldDeclaration}*
* {@linkplain ASTMethodDeclaration MethodDeclaration}
* {@linkplain ASTBodyDeclaration BodyDeclaration}*
*
*
* @see JEP 477: Implicitly Declared Classes and Instance Main Methods (Third Preview) (Java 23)
*/
@Experimental("Implicitly Declared Classes and Instance Main Methods is a Java 22 / Java 23 Preview feature")
public final class ASTImplicitClassDeclaration extends AbstractTypeDeclaration {
ASTImplicitClassDeclaration(int id) {
super(id);
}
@Override
protected R acceptVisitor(JavaVisitor super P, ? extends R> visitor, P data) {
return visitor.visit(this, data);
}
@Override
public @NonNull String getSimpleName() {
return "";
}
}