HTMLDocument createHTMLDocument(String title);
title
The title of the document. This text is used as the content of the <title> element of the newly created document.
The new HTMLDocument object.
This method creates a new HTMLDocument object with a skeletal document tree that includes the specified title. The documentElement property of the returned object is an <l> element, and this root element has <head> and <body> tags as its children. The <head> element in turn has a <title> child, which has the specified title string as its child.
createHTMLDocument( ) is defined not by the DOMImplementation interface but by its HTMLDOMImplementation subinterface. If an implementation supports the "HTML" feature, its DOMImplementation object implements this method.
DOMImplementation.createDocument( )