com.waveset.adapter
Class SAPResourceAdapter.Function

java.lang.Object
  extended bycom.waveset.adapter.SAPResourceAdapter.Function
Enclosing class:
SAPResourceAdapter

protected class SAPResourceAdapter.Function
extends java.lang.Object


Constructor Summary
protected SAPResourceAdapter.Function(java.lang.String bapiName)
          Create a JCO.Function to execute on an SAP system
protected SAPResourceAdapter.Function(java.lang.String bapiName, boolean retryOnFailedConnection)
          Create a JCO.Function to execute on an SAP system
protected SAPResourceAdapter.Function(java.lang.String bapiName, java.lang.String identity)
          Create a JCO.Function to execute on an SAP system
protected SAPResourceAdapter.Function(java.lang.String bapiName, java.lang.String identity, boolean retryOnFailedConnection)
          Create a JCO.Function to execute on an SAP system
 
Method Summary
protected  void appendTableRow(com.sap.mw.jco.JCO.Table table, java.lang.String rowName, java.lang.String value)
           
protected  void finalize()
          Return the JCO.Function to free memory quickly
protected  com.sap.mw.jco.JCO.ParameterList getExportParameterList()
           
protected  com.sap.mw.jco.JCO.Field getField(java.lang.String fieldName)
           
protected  com.sap.mw.jco.JCO.Field getImportField(java.lang.String fieldName)
           
protected  com.sap.mw.jco.JCO.Function getJCOFunction()
          Returns the JCO.Function object.
protected  java.lang.String getName()
          Returns the name of the JCO.Function.
protected  com.sap.mw.jco.JCO.Structure getStructure(java.lang.String structureName)
          Retrieves the export structure with the specified name.
protected  com.sap.mw.jco.JCO.Table getTable(java.lang.String tableName)
          Retrieves the table with the specified name.
protected  void recreate()
           
protected  void setField(java.lang.String fieldName, java.lang.String value)
           
protected  void setInputParameterList(java.util.Map map)
          Sets the input parameter list for this BAPI
protected  void setTableRowValue(com.sap.mw.jco.JCO.Table table, java.lang.String rowName, java.lang.Object value)
           
protected  void setUserField(java.lang.String identity)
           
protected  void setValues(java.lang.String structOrTable, java.lang.String attributeName, java.lang.Object value, boolean update)
           
 java.lang.String toString()
           
protected  void writeXML(java.lang.String fileName)
           
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SAPResourceAdapter.Function

protected SAPResourceAdapter.Function(java.lang.String bapiName,
                                      java.lang.String identity)
                               throws com.sap.mw.jco.JCO.Exception
Create a JCO.Function to execute on an SAP system

Parameters:
bapiName -
identity -
Throws:
JCO.Exception

SAPResourceAdapter.Function

protected SAPResourceAdapter.Function(java.lang.String bapiName)
                               throws com.sap.mw.jco.JCO.Exception
Create a JCO.Function to execute on an SAP system

Parameters:
bapiName -
Throws:
JCO.Exception

SAPResourceAdapter.Function

protected SAPResourceAdapter.Function(java.lang.String bapiName,
                                      java.lang.String identity,
                                      boolean retryOnFailedConnection)
                               throws com.sap.mw.jco.JCO.Exception
Create a JCO.Function to execute on an SAP system

Parameters:
bapiName -
identity -
retryOnFailedConnection -
Throws:
JCO.Exception

SAPResourceAdapter.Function

protected SAPResourceAdapter.Function(java.lang.String bapiName,
                                      boolean retryOnFailedConnection)
                               throws com.sap.mw.jco.JCO.Exception
Create a JCO.Function to execute on an SAP system

Parameters:
bapiName -
retryOnFailedConnection -
Throws:
JCO.Exception
Method Detail

getName

protected java.lang.String getName()
Returns the name of the JCO.Function. For example "BAPI_USER_CHANGE"

Returns:
the name of the JCO.Function that was created.

getJCOFunction

protected com.sap.mw.jco.JCO.Function getJCOFunction()
Returns the JCO.Function object.

Returns:
the JCO.Function that was created.

getTable

protected com.sap.mw.jco.JCO.Table getTable(java.lang.String tableName)
                                     throws com.sap.mw.jco.JCO.Exception
Retrieves the table with the specified name. WARNING: The returned table should only be used to read data from the table. If writing data to the table, use 'appendTableRow' in order to have the function call recreated correctly if the connection to the SAP system fails.

Parameters:
tableName - - table name to retrieve.
Returns:
the JCO.Table
Throws:
JCO.Exception

getStructure

protected com.sap.mw.jco.JCO.Structure getStructure(java.lang.String structureName)
                                             throws com.sap.mw.jco.JCO.Exception
Retrieves the export structure with the specified name.

Parameters:
structureName -
Returns:
the specified JCO.Structure
Throws:
JCO.Exception

getExportParameterList

protected com.sap.mw.jco.JCO.ParameterList getExportParameterList()
                                                           throws com.sap.mw.jco.JCO.Exception
Throws:
com.sap.mw.jco.JCO.Exception

getField

protected com.sap.mw.jco.JCO.Field getField(java.lang.String fieldName)
                                     throws com.sap.mw.jco.JCO.Exception
Throws:
com.sap.mw.jco.JCO.Exception

getImportField

protected com.sap.mw.jco.JCO.Field getImportField(java.lang.String fieldName)
                                           throws com.sap.mw.jco.JCO.Exception
Throws:
com.sap.mw.jco.JCO.Exception

recreate

protected void recreate()
                 throws com.sap.mw.jco.JCO.Exception
Throws:
com.sap.mw.jco.JCO.Exception

setValues

protected void setValues(java.lang.String structOrTable,
                         java.lang.String attributeName,
                         java.lang.Object value,
                         boolean update)
                  throws com.sap.mw.jco.JCO.Exception
Throws:
com.sap.mw.jco.JCO.Exception

setUserField

protected void setUserField(java.lang.String identity)

setField

protected void setField(java.lang.String fieldName,
                        java.lang.String value)
                 throws com.sap.mw.jco.JCO.Exception
Throws:
com.sap.mw.jco.JCO.Exception

setInputParameterList

protected void setInputParameterList(java.util.Map map)
Sets the input parameter list for this BAPI

Parameters:
map - - a map of name value pairs

appendTableRow

protected void appendTableRow(com.sap.mw.jco.JCO.Table table,
                              java.lang.String rowName,
                              java.lang.String value)

setTableRowValue

protected void setTableRowValue(com.sap.mw.jco.JCO.Table table,
                                java.lang.String rowName,
                                java.lang.Object value)

writeXML

protected void writeXML(java.lang.String fileName)
                 throws com.sap.mw.jco.JCO.Exception
Throws:
com.sap.mw.jco.JCO.Exception

finalize

protected void finalize()
Return the JCO.Function to free memory quickly


toString

public java.lang.String toString()