use of com.twinsoft.convertigo.beans.connectors.SapJcoConnector in project convertigo by convertigo.
the class SapJcoTransaction method runCore.
@Override
public void runCore() throws EngineException {
connector = ((SapJcoConnector) parent);
try {
Engine.logBeans.debug("[SAP transaction] BAPI named '" + bapiName + "' executing ...");
Document jcoDoc = connector.executeTransaction(this);
Engine.logBeans.debug("[SAP transaction] BAPI named '" + bapiName + "' executed.");
if (jcoDoc != null) {
Element sap_output = jcoDoc.getDocumentElement();
if (sap_output != null) {
Element outputDocumentRootElement = context.outputDocument.getDocumentElement();
Element jcoImported = (Element) context.outputDocument.importNode(sap_output, true);
outputDocumentRootElement.appendChild(jcoImported);
score += 1;
}
}
} catch (Exception e) {
connector.setData(null);
throw new EngineException("An unexpected error occured while executing transaction.", e);
} finally {
}
}
Aggregations