public static Collection<Element> getChildElementList(Element element) {
        List<Element> children = new ArrayList<>();
        if (element != null) {
            for (Node node = element.getFirstChild(); node != null; node = node.getNextSibling()) {
                if (node.getNodeType() == Node.ELEMENT_NODE) {
                    children.add((Element) node);
                }
            }
        }
        return children;
    }
Encodes a char to XML-valid form replacing &,',",<,> with special XML encoding.

@param ch char to convert
@return XML-encoded text
chat2db-server/chat2db-server-web/chat2db-server-web-api/src/main/java/ai/chat2db/server/web/api/util/XMLUtils.java