Adapter for SAP 10.1 | webMethods Adapter for SAP Documentation | webMethods Adapter for SAP Installation and User’s Guide Documentation | Installing, Upgrading, and Uninstalling webMethods Adapter for SAP 10.1 | Upgrading to Adapter for SAP 10.1 | Upgrading from Adapter for SAP 6.5 | Manually Upgrading | Java IDoc API
 
Java IDoc API
Software AG suggests that you replace any usage of the classes from com.wm.pkg.sap.idoc Java package in your custom application code with the corresponding classes from com.wm.adapter.sap.idoc package. For more information about these classes, see webMethods Adapter for SAP IDoc Java API which is available on Adapter for SAP 10.1 home page.
As described in the previous section, the com.wm.adapter.sap.idoc package is changed from Adapter for SAP 6.5 to Adapter for SAP 10.1 as a result of changes in the SAP IDoc Library 3. Therefore, you must modify all Java application code based on the com.wm.adapter.sap.idoc package of Adapter for SAP 6.5 to compile and run properly with Adapter for SAP 10.1. Do the following:
*Replace any references to com.sap.mw.idoc with com.sap.conn.idoc.
*Replace old SAP IDoc Class Library 2 classes with their IDoc Class Library 3 equivalents described in the table above.
*Rename all IDataRecord.setField(..) calls to IDataRecord.setValue(..).
*Place calls to the IDataDocumentList.addDocument(..) methods in a try/catch-block to avoid IDocExceptions when the IDoc type of the new IDoc document is different from the IDoc type of the other IDocs in the list.
*Substitute addDocument(..) methods with calls to the add(..) or addNew(..) methods because the addDocument(..) methods have been removed from the IDocDocumentList class.