html5 doc,JEP 224: HTML5 Javadoc

Summary

Enhance the javadoc tool to generate HTML5 markup.

Goals

Provide an option to the standard doclet to request either HTML 4 or HTML5 output.

The HTML5 markup is semantic, i.e., clearly separating meaning from

style and content. The parts of the pages generated by the standard doclet

using HTML5 markup satisfy accessibility requirements.

Non-Goals

It is a not a goal to replace the current three-frame/no-frame structure of the

generated HTML pages; that may be the subject of a future JEP.

It is not a goal to mandate the use of HTML5 in documentation comments,

nor is it a goal to provide the ability to convert documentation comments written using

HTML 4 to HTML5.

Motivation

In JDK 8 and older releases, the standard doclet generated pages in HTML 4.01,

which is an old standard, and not not provide support for satisfying accessibility requirements.

HTML5 is the latest standard for HTML. HTML5 increases the semantic value of web

pages and makes it easier to create accessible web pages.

Description

A command-line option is added to the standard doclet to request a

specific type of output markup. HTML4, which is the current type,

will be the default. HTML5 will become the default in JDK 10.

The semantic value of the generated HTML is improved by using

structural HTML5 elements such as header, footer, nav, etc.

The HTML5 markup implements the WAI-ARIA standard for

accessibility. Specific roles are assigned to elements in the

HTML document using the role attribute.

The -Xdoclint feature is update to check documentation comments

for common errors, based upon the requested type of output markup.

Testing

Tests are provided to ensure that:

The HTML5 markup is valid

The HTML5 markup is accessible

The new command-line option works correctly

The HTML5 markup works across all supported browsers

The lack of automated tools to test accessibility hampers

comprehensive accessibility testing. A representative sample

of different types of pages can checked using online web-based

tools.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值