String serviceName = axisService.getName();
String name = serviceName + "HttpBinding";
QName bindingName = new QName(name);
AxisBinding axisBinding = (bindingCache != null) ? (AxisBinding) bindingCache
.get(name)
: null;
if (axisBinding == null) {
axisBinding = new AxisBinding();
axisBinding.setName(bindingName);
axisBinding.setType(WSDL2Constants.URI_WSDL2_HTTP);
axisBinding.setProperty(WSDL2Constants.ATTR_WHTTP_METHOD, "POST");
for (Iterator iterator = axisService.getChildren(); iterator
.hasNext();) {
AxisOperation operation = (AxisOperation) iterator.next();
AxisBindingOperation axisBindingOperation = new AxisBindingOperation();
QName operationQName = operation.getName();
axisBindingOperation.setName(operationQName);
axisBindingOperation.setAxisOperation(operation);
String httpLocation = operationQName.getLocalPart();
axisBindingOperation.setProperty(WSDL2Constants.ATTR_WHTTP_LOCATION, httpLocation);
axisBinding.addChild(axisBindingOperation.getName(),
axisBindingOperation);
populateBindingOperation(axisService, axisBinding,
axisBindingOperation);
}
if (bindingCache != null) {
bindingCache.put(name, axisBinding);
}
}
axisBinding.setParent(axisEndpoint);
axisEndpoint.setBinding(axisBinding);
}