@@ -0,0 +1,1679 @@
+package utils;%0A%0Aimport java.io.FileOutputStream;%0Aimport java.io.IOException;%0A%0Aimport javax.xml.parsers.DocumentBuilder;%0Aimport javax.xml.parsers.DocumentBuilderFactory;%0Aimport javax.xml.parsers.ParserConfigurationException;%0Aimport javax.xml.transform.Transformer;%0Aimport javax.xml.transform.TransformerException;%0Aimport javax.xml.transform.TransformerFactory;%0Aimport javax.xml.transform.dom.DOMSource;%0Aimport javax.xml.transform.stream.StreamResult;%0A%0Aimport org.w3c.dom.Document;%0Aimport org.w3c.dom.Element;%0A%0Apublic class ConstructorsForXML %7B%0A%0A%09public void ParamLangXML() %7B%0A%09%09DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();%0A%09%09try %7B%0A%09%09%09builder = factory.newDocumentBuilder();%0A%09%09%7D catch (ParserConfigurationException e) %7B%0A%09%09%09e.printStackTrace();%0A%09%09%7D%0A%09%7D%0A%0A%09DocumentBuilder builder;%0A%0A%09/**%0A%09 *    XML %0A%09 */%0A%09public void WriteParamXML() throws TransformerException, IOException %7B%0A%0A%09%09Document doc = builder.newDocument();%0A%09%09Element RootElement = doc.createElement(%22proxy%22);%0A%0A%09%09Element NameElementTitle = doc.createElement(%22use%22);%0A%09%09NameElementTitle.appendChild(doc.createTextNode(%22true%22));%0A%09%09RootElement.appendChild(NameElementTitle);%0A%0A%09%09Element NameElementCompile = doc.createElement(%22host%22);%0A%09%09NameElementCompile.appendChild(doc.createTextNode(%22127.0.0.1%22));%0A%09%09RootElement.appendChild(NameElementCompile);%0A%0A%09%09Element NameElementRuns = doc.createElement(%22port%22);%0A%09%09NameElementRuns.appendChild(doc.createTextNode(%228080%22));%0A%09%09RootElement.appendChild(NameElementRuns);%0A%0A%09%09doc.appendChild(RootElement);%0A%0A%09%09Transformer t = TransformerFactory.newInstance().newTransformer();%0A%09%09t.transform(new DOMSource(doc), new StreamResult(new FileOutputStream(%22proxy.xml%22)));%0A%0A%09%7D%0A%7D%0A

Add xml writer sample