w2phtml/source/java/writer2latex/xhtml/Debug.java
2020-12-13 14:08:04 +01:00

23 lines
520 B
Java

package writer2latex.xhtml;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
import org.w3c.dom.ls.DOMImplementationLS;
import org.w3c.dom.ls.LSSerializer;
public class Debug {
public static void printNode(Node node){
Document document = node.getOwnerDocument();
DOMImplementationLS domImplLS = (DOMImplementationLS) document
.getImplementation();
LSSerializer serializer = domImplLS.createLSSerializer();
String str = serializer.writeToString(node);
System.out.println(str);
}
}