Skip to content

Commit

Permalink
Add language hints to getDisplayName() and getDescription()
Browse files Browse the repository at this point in the history
  • Loading branch information
timtebeek committed Dec 23, 2024
1 parent a2ab406 commit 216c0c1
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ private void writeRecipeClass(JCTree.JCClassDecl classDecl, boolean outerClassRe
out.write("@Generated(\"" + GENERATOR_NAME + "\")\n");
out.write("public class " + outerClassName + " extends Recipe {\n");
out.write(" /**\n");
out.write(" * Instantiates a new instance.\n");
out.write(" * Instantiates a new instance.\n"); // For -Xdoclint
out.write(" */\n");
out.write(" public " + outerClassName + "() {}\n\n");
out.write(recipeDescriptor(classDecl,
Expand Down Expand Up @@ -545,11 +545,13 @@ private String recipeDescriptor(JCTree.JCClassDecl classDecl, String defaultDisp

String recipeDescriptor = " @Override\n" +
" public String getDisplayName() {\n" +
" //language=markdown\n" +
" return \"" + displayName + "\";\n" +
" }\n" +
"\n" +
" @Override\n" +
" public String getDescription() {\n" +
" //language=markdown\n" +
" return \"" + description + "\";\n" +
" }\n" +
"\n";
Expand Down

0 comments on commit 216c0c1

Please sign in to comment.