src/main/java/org/jsoup/helper/W3CDom.java
/**
     * Converts a jsoup element into the provided W3C Document. If required, you can set options on the output
     * document before converting.
     *
     * @param in jsoup element
     * @param out w3c doc
     * @see org.jsoup.helper.W3CDom#fromJsoup(org.jsoup.nodes.Element)
     */
Converts a jsoup element into the provided W3C Document. If required, you can set options on the output
document before converting.

@param in jsoup element
@param out w3c doc
@see org.jsoup.helper.W3CDom#fromJsoup(org.jsoup.nodes.Element)
Converts a jsoup element into the provided W3C Document . If required you can set options on the output document before converting . @param in jsoup element @param out w3c doc @see org . jsoup . helper . W3CDom#fromJsoup ( org . jsoup . nodes . Element )
public void convert(org.jsoup.nodes.Element in, Document out) {
        W3CBuilder builder = new W3CBuilder(out);
        org.jsoup.nodes.Document inDoc = in.ownerDocument();
        if (inDoc != null) {
            if (!StringUtil.isBlank(inDoc.location())) {
                out.setDocumentURI(inDoc.location());
            }
            builder.syntax = inDoc.outputSettings().syntax();
        }
        org.jsoup.nodes.Element rootEl = in instanceof org.jsoup.nodes.Document ? in.child(0) : in; 
        NodeTraversor.traverse(builder, rootEl);
    }
public void convert ( org . jsoup . nodes . Element in , Document out ) { W3CBuilder builder = new W3CBuilder ( out ) ; org . jsoup . nodes . Document inDoc = in . ownerDocument ( ) ; if ( inDoc != null ) { if ( ! StringUtil . isBlank ( inDoc . location ( ) ) ) { out . setDocumentURI ( inDoc . location ( ) ) ; } builder . syntax = inDoc . outputSettings ( ) . syntax ( ) ; } org . jsoup . nodes . Element rootEl = in instanceof org . jsoup . nodes . Document ? in . child ( 0 ) : in ; NodeTraversor . traverse ( builder , rootEl ) ; }
Converts a jsoup element into the provided W3C Document.
Converts a jsoup element into the provided W3C Document .
// skip the #root node if a Document