code: protected void moveChildren(Element parent, Element destination)
      {
          NodeList children = parent.getChildNodes();
          while (children.getLength() > 0) {
              destination.appendChild(parent.removeChild(parent.getFirstChild()));
          }
      }
docs: Moves all child elements of the parent into destination element.
  
  @param parent the parent {@link Element}.
  @param destination the destination {@link Element}.