private JavaPort processPort(JavaModel model, ServiceInfo si, EndpointInfo port) throws ToolException {
BindingInfo binding = port.getBinding();
String portType = binding.getInterface().getName().getLocalPart();
JavaInterface intf = PortTypeProcessor.getInterface(context, si, binding.getInterface());
JavaPort jport = new JavaPort(NameUtil.mangleNameToClassName(port.getName().getLocalPart()));
jport.setPackageName(intf.getPackageName());
jport.setPortName(port.getName().getLocalPart());
jport.setBindingAdress(port.getAddress());
jport.setBindingName(binding.getName().getLocalPart());
jport.setPortType(portType);
jport.setInterfaceClass(intf.getName());
bindingType = getBindingType(binding);
if (bindingType == null) {
org.apache.cxf.common.i18n.Message msg =
new org.apache.cxf.common.i18n.Message("BINDING_SPECIFY_ONE_PROTOCOL",
LOG,
binding.getName());
throw new ToolException(msg);
}
if (isSoapBinding()) {
SoapBinding spbd = SOAPBindingUtil.getProxy(SoapBinding.class, this.bindingObj);
jport.setStyle(SOAPBindingUtil.getSoapStyle(spbd.getStyle()));
jport.setTransURI(spbd.getTransportURI());
}
Collection<BindingOperationInfo> operations = binding.getOperations();
for (BindingOperationInfo bop : operations) {
processOperation(model, bop, binding);
}
jport.setJavaDoc(port.getDocumentation());
return jport;
}