WSDLDescription wom = this.configuration.getWom();
Map bindings = wom.getBindings();
WSDLBinding axisBinding = null;
WSDLService axisService = null;
if (bindings==null){
throw new CodeGenerationException("Binding needs to be present!");
}
Collection bindingCollection = bindings.values();
for (Iterator iterator = bindingCollection.iterator(); iterator.hasNext();) {
axisBinding = (WSDLBinding)iterator.next();
//write interfaces
Map services = wom.getServices();
if (!services.isEmpty()) {
if (services.size() == 1) {
axisService = (WSDLService) services.values().toArray()[0];
} else {
throw new UnsupportedOperationException(
"Single service WSDL files only");
}
}
//
writeInterface(axisBinding);
//write interface implementations
writeInterfaceImplementation(axisBinding, axisService);
//write the call back handlers
writeCallBackHandlers(axisBinding);
//write the test classes
writeTestClasses(axisBinding);
//write the databinding supporters
writeDatabindingSupporters(axisBinding);
//write a dummy implementation call for the tests to run.
//writeTestSkeletonImpl(axisBinding);
//write a testservice.xml that will load the dummy skeleton impl for testing
//writeTestServiceXML(axisBinding);
}
} catch (Exception e) {
throw new CodeGenerationException(e);
}
}