code: public static void moveChildren(Element from, Element to) {
          if (from == null || to == null || from == to) return;
          for (int k = from.getChildCount() - 1; k >= 0; k--) {
              Node node = from.getChild(k);
              from.removeChild(node);
              to.insertFirst(node);
          }
      }
docs: Moves all children of "from" element onto "to" element.