use of org.talend.designer.esb.webservice.ws.wsdlinfo.Function in project tesb-studio-se by Talend.
the class TESBConsumerNodeAdapter method setNodeSetting.
@Override
public IStatus setNodeSetting(ServiceSetting setting) {
node.setParamValue("ENDPOINT", setting.getWsdlLocation());
try {
String wsdlString = setting.getCompressedAndEncodedWSDL();
node.setParamValue("WSDL_CONTENT", wsdlString);
} catch (Exception e) {
throw new IllegalStateException("Unable to create wsdl content", e);
}
Function currentFunction = setting.getFunction();
node.setParamValue(PORT_NAME, currentFunction.getPortName());
node.setParamValue("METHOD_NS", currentFunction.getNameSpaceURI());
node.setParamValue(METHOD, currentFunction.getName());
node.setParamValue(SERVICE_NS, currentFunction.getServiceNameSpace());
node.setParamValue(SERVICE_NAME, currentFunction.getServiceName());
node.setParamValue("PORT_NS", currentFunction.getServiceNameSpace());
node.setParamValue("SOAP_ACTION", currentFunction.getSoapAction());
final String endpoint = node.getParamStringValue("ESB_ENDPOINT");
if (endpoint == null || !endpoint.startsWith("context.")) {
node.setParamValue("ESB_ENDPOINT", TalendTextUtils.addQuotes(currentFunction.getAddressLocation()));
}
node.setParamValue("COMMUNICATION_STYLE", currentFunction.getCommunicationStyle());
return Status.OK_STATUS;
}
Aggregations