Class MarkdownDocumentationCommentsExamples
java.lang.Object
net.jrodolfo.java_evolution.java23.markdown_documentation_comments.MarkdownDocumentationCommentsExamples
Demonstrates Java 23 Markdown documentation comments by invoking JavaDoc.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordCaptures the JavaDoc child process result. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateDocumentedSource(Path sourceDirectory) Creates a Java source file that uses Markdown documentation comments.generateJavaDoc(Path sourceFile, Path outputDirectory) Runs the JavaDoc tool for one source file.
-
Constructor Details
-
MarkdownDocumentationCommentsExamples
public MarkdownDocumentationCommentsExamples()
-
-
Method Details
-
createDocumentedSource
Creates a Java source file that uses Markdown documentation comments.- Parameters:
sourceDirectory- directory where the source file should be written- Returns:
- path to the generated source file
- Throws:
IOException- when the source file cannot be written
-
generateJavaDoc
public MarkdownDocumentationCommentsExamples.JavaDocResult generateJavaDoc(Path sourceFile, Path outputDirectory) throws IOException, InterruptedException Runs the JavaDoc tool for one source file.- Parameters:
sourceFile- Java source file to documentoutputDirectory- JavaDoc output directory- Returns:
- child-process result
- Throws:
IOException- when the JavaDoc process cannot be startedInterruptedException- when interrupted while waiting for JavaDoc
-