
package old;
 
import static scriptbuilder.structures.XMLBuilder.prettyPrintXML;

public class PrettyPrintDemo {
 
    public static void main(String[] args) {
 String xmlString = "<SCRIPT_EVENT><TIME_INDEX>00:00:00</TIME_INDEX><INCIDENT LogNum=\"101\"/><COLOR b=\"255\" g=\"0\" r=\"0\"/><CAD_DATA><CAD_INCIDENT_EVENT><DETAIL>abc</DETAIL></CAD_INCIDENT_EVENT></CAD_DATA></SCRIPT_EVENT>";
 //String xmlString = "<SCRIPT_EVENT><TIME_INDEX>00:00:45</TIME_INDEX><INCIDENT LogNum=\"101\">Ice Cream</INCIDENT><CMS_EVALUATION cmsID=\"72\" type=\"new\"> <LOCATION>SB 55 @ WARNER AVE</LOCATION><SAMPLE_MESSAGE><CMS_LINE>ACCIDENT AHEAD</CMS_LINE><CMS_LINE>AT 405 OVERPASS</CMS_LINE></SAMPLE_MESSAGE></CMS_EVALUATION></SCRIPT_EVENT>";
        System.out.println("Input XML : \n" + xmlString);
        // Print the masked XML
        System.out.println("\nXML after formatting : \n" + prettyPrintXML(xmlString));
    }

}