MCPcopy Create free account
hub / github.com/HtmlUnit/htmlunit / cloneNode

Method cloneNode

src/main/java/org/htmlunit/javascript/host/dom/Node.java:517–523  ·  view source on GitHub ↗

Clones this node. @param deep if true, recursively clones all descendants @return the newly cloned node

(final boolean deep)

Source from the content-addressed store, hash-verified

515 * @return the newly cloned node
516 */
517 @JsxFunction
518 public Node cloneNode(final boolean deep) {
519 final DomNode domNode = getDomNodeOrDie();
520 final DomNode clonedNode = domNode.cloneNode(deep);
521
522 return getJavaScriptNode(clonedNode);
523 }
524
525 /**
526 * Check if 2 nodes are equals.

Callers

nothing calls this directly

Implementers 1

DomNodesrc/main/java/org/htmlunit/html/DomNod

Calls 3

cloneNodeMethod · 0.95
getJavaScriptNodeMethod · 0.95
getDomNodeOrDieMethod · 0.45

Tested by

no test coverage detected