-
Notifications
You must be signed in to change notification settings - Fork 34
Expand file tree
/
Copy pathMarkdownComments.java
More file actions
46 lines (35 loc) · 1.31 KB
/
MarkdownComments.java
File metadata and controls
46 lines (35 loc) · 1.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
package org.javademos.java23.jep467;
import org.javademos.commons.IDemo;
/// # Demo for JDK 23 feature JEP 467 - Markdown Documentation Comments
///
/// ## JEP history
/// - JDK 23: [JEP 467 - Markdown Documentation Comments](https://openjdk.org/jeps/467)
///
/// ## Further reading
/// - [Java Enhances Documentation with Markdown Support](https://www.infoq.com/news/2024/05/jep467-markdown-in-javadoc/)
///
/// @author alois.seckar@gmail.com
@SuppressWarnings("DanglingJavadoc") // because of the examples
public class MarkdownComments implements IDemo {
@Override
public void demo() {
info(467);
}
// Markdown syntax is now possible in Javadoc comments
// It has to be started with different prefix - /// instead of /**
// BEFORE JDK 23 - Javadoc header
/**
* <h1>
* Demo for JDK 23 feature <strong>JEP 467 - Markdown Documentation Comments</strong>
* </h1>
*/
// AFTER JDK 23 - Javadoc header
/// # Demo for JDK 23 feature **JEP 467 - Markdown Documentation Comments**
// ISSUES / LIMITATIONS
// @see and external links
// -----------------------
// /// @see [JEP 467](https://openjdk.org/jeps/467)
// md syntax is currently not possible
// /// @see <a href="https://openjdk.org/jeps/467">JEP 467</a>
// html <a> tag renders fine...
}