class NoUnderscoresInIntegerLiteralsValidator extends VisitorValidator {

    @Override
    public void visit(IntegerLiteralExpr n, ProblemReporter arg) {
        validate(n, arg);
        super.visit(n, arg);
    }

    @Override
    public void visit(LongLiteralExpr n, ProblemReporter arg) {
        validate(n, arg);
        super.visit(n, arg);
    }

    private static void validate(LiteralStringValueExpr n, ProblemReporter arg) {<FILL_FUNCTION_BODY>}
}

        if (n.getValue().contains("_")) {
            arg.report(n, "Underscores in literal values are not supported.");
        }
    
<methods>public non-sealed void <init>() ,public void accept(com.github.javaparser.ast.Node, com.github.javaparser.ast.validator.ProblemReporter) <variables>