1 package org.apache.axis2.wsdl.codegen.writer; 2 3 import org.apache.axis2.wsdl.codegen.XSLTConstants; 4 import org.apache.axis2.wsdl.util.FileWriter; 5 6 import java.io.File ; 7 import java.io.FileOutputStream ; 8 9 26 public class ServiceXMLWriter extends ClassWriter{ 27 28 29 public ServiceXMLWriter(String outputFileLocation) { 30 this.outputFileLocation = new File (outputFileLocation); 31 } 32 33 public ServiceXMLWriter(File outputFileLocation,int language) { 34 this.outputFileLocation = outputFileLocation; 35 this.language = language; 36 } 37 38 41 public void loadTemplate(){ 42 Class clazz = this.getClass(); 43 this.xsltStream = clazz.getResourceAsStream(XSLTConstants.XSLTServiceXMLTemplates.GENERAL_SERVICE_TEMPLATE); 44 } 45 46 public void createOutFile(String packageName, String fileName) throws Exception { 47 File outputFile = FileWriter.createClassFile(outputFileLocation,packageName,"service",".xml"); 48 this.stream = new FileOutputStream (outputFile); 49 } 50 } 51 52 | Popular Tags |