InOutInteger interface

Syntax
public ianywhere.ml.script.InOutInteger
Remarks

Passed into methods to enable the functionality of an in/out parameter passed to a SQL script.

Members

All members of ianywhere.ml.script.InOutInteger, including all inherited members.

Example

The following call to a MobiLink system procedure registers a Java method called handleError as the script for the handle_error connection event when synchronizing the script version ver1.

CALL ml_add_java_connection_script(
    'ver1',
    'handle_error',
    'ExamplePackage.ExampleClass.handleError' )

Following is the sample Java method handleError. It processes an error based on the data that is passed in. It also determines the resulting error code.

public String handleError(
  ianywhere.ml.script.InOutInteger actionCode,
  int errorCode,
  String errorMessage,
  String user,
  String table ) {
  int new_ac;
  if( user == null ) {
    new_ac = handleNonSyncError( errorCode,
    errorMessage ); }
  else if( table == null ) {
    new_ac = handleConnectionError( errorCode,
    errorMessage, user ); }
  else {
    new_ac = handleTableError( errorCode,
    errorMessage, user, table ); 
  }
  // Keep the most serious action code.
  if( actionCode.getValue() < new_ac ) {
    actionCode.setValue( new_ac ); 
  }
}

getValue method
setValue method