public class Param {
/**
* <p>
* <b>Usage examples</b> Suppose we want a list of files
* {@snippet lang = "java" :
*
* List<Path> listSourceFiles(Path dir) throws IOException {
* List<Path> result = new ArrayList<>();
* try (DirectoryStream<Path> stream = Files.newDirectoryStream(dir, "*.{c,h,cpp,hpp,java}")) {
* for (Path entry : stream) {
* result.add(entry);
* }
* } catch (DirectoryIteratorException ex) {
* // I/O error encountered during the iteration, the cause is an IOException
* throw ex.getCause();
* }
* return result;
* }
*
* }
*
*/
public int test(int i) {
return i;
}
}
does not display type parameters for List or DirectoryStream. This is because the type parameters are being passed directly into the html and treated as unknown tags. They need to be escaped.
The following example:
does not display type parameters for List or DirectoryStream. This is because the type parameters are being passed directly into the html and treated as unknown tags. They need to be escaped.