use of org.apache.cxf.tools.wsdlto.core.AbstractGenerator in project cxf by apache.
the class JAXWSFrontEndProcessor method process.
@SuppressWarnings("unchecked")
public void process() throws ToolException {
checkJaxwsClass();
List<ServiceInfo> services = (List<ServiceInfo>) context.get(ToolConstants.SERVICE_LIST);
ServiceInfo serviceInfo = services.get(0);
JavaInterface jinf = JavaFirstUtil.serviceInfo2JavaInf(serviceInfo);
String className = (String) context.get(ToolConstants.IMPL_CLASS);
if (className != null && className.equals(jinf.getFullClassName())) {
jinf.setName(jinf.getName() + SEI_SUFFIX);
}
JavaModel jm = new JavaModel();
jm.addInterface("inf", jinf);
jinf.setJavaModel(jm);
context.put(JavaModel.class, jm);
context.put(ToolConstants.SERVICE_NAME, serviceInfo.getName());
EndpointInfo endpointInfo = serviceInfo.getEndpoints().iterator().next();
context.put(ToolConstants.PORT_NAME, endpointInfo.getName());
generators.add(new JaxwsSEIGenerator());
generators.add(new JaxwsImplGenerator());
generators.add(new JaxwsServerGenerator());
generators.add(new JaxwsClientGenerator());
generators.add(new AntGenerator());
for (AbstractGenerator generator : generators) {
generator.generate(context);
}
}
use of org.apache.cxf.tools.wsdlto.core.AbstractGenerator in project cxf by apache.
the class SimpleFrontEndProcessor method process.
@SuppressWarnings("unchecked")
public void process() throws ToolException {
List<ServiceInfo> services = (List<ServiceInfo>) context.get(ToolConstants.SERVICE_LIST);
ServiceInfo serviceInfo = services.get(0);
JavaInterface jinf = JavaFirstUtil.serviceInfo2JavaInf(serviceInfo);
JavaModel jm = new JavaModel();
jm.addInterface("inf", jinf);
jinf.setJavaModel(jm);
context.put(JavaModel.class, jm);
generators.add(new SimpleSEIGenerator());
generators.add(new SimpleImplGenerator());
generators.add(new SimpleServerGenerator());
generators.add(new SimpleClientGenerator());
generators.add(new AntGenerator());
for (AbstractGenerator generator : generators) {
generator.generate(context);
}
}
Aggregations