org.jaxws.stub2html.view.freemarker.FreemarkerWebServiceDisplayEngine Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of wsdl2html Show documentation
Show all versions of wsdl2html Show documentation
A java tool to convert wsdl xml to readable doc
package org.jaxws.stub2html.view.freemarker;
import org.jaxws.stub2html.model.WebServiceStubSet;
import org.jaxws.stub2html.view.WebServiceDisplayEngine;
import freemarker.template.Configuration;
import freemarker.template.DefaultObjectWrapper;
import freemarker.template.Template;
/**
*
* @author chenjianjx
*
*/
public abstract class FreemarkerWebServiceDisplayEngine extends WebServiceDisplayEngine {
protected Configuration configuration;
public FreemarkerWebServiceDisplayEngine() {
super();
configuration = new Configuration();
configuration.setLocalizedLookup(false);
configuration.setObjectWrapper(new DefaultObjectWrapper());
}
@Override
public String displayWebSerivce(WebServiceStubSet serviceStubSet) {
Template template = getTemplate();
FreemarkerWebServiceDisplayer displayer = new FreemarkerWebServiceDisplayer(template, serviceStubSet);
return displayer.displayWebSerivce();
}
protected abstract Template getTemplate();
}