uCosminexus Service Platform, Basic Development Guide
(1) Function used
Use the custom function to invoke a Java program created by the user.
The following figure shows how to invoke a Java program from the custom function. Note that in the custom function, invoking a Java program is called as transformation function.
Figure 6-24 Invoking a Java program from the custom function (transformation function)
(2) Setting procedure
The following procedure describes how to invoke a Java program created by the user:
- In the Eclipse menu, choose Window and Settings.
The Settings dialog box appears.
- In the left of the dialog box, choose HCSC--Definer and Data transformation.
The settings of the Data Transformation Definition screen appear on the right side of the dialog box.
- Click the Custom function tab.
The Custom function tab of the Settings dialog box appears.
- Specify the transformation function definition file and click OK button.
- Choose the custom function from the palette (custom) and deploy it in the mapping viewer.
- Set the mapping line.
The number of mapping lines to be set is the same as for the argument of the invoked Java program.
- Open the Custom dialog box by either of the following methods:
- Right click the custom function and choose Settings.
- Double--click the custom function.
- Click Choose transformation function.
The Choose transformation function dialog box appears.
- Choose the method to be invoked from the custom function and click OK button.
The Choose transformation function dialog box closes and the Custom dialog box appears.
- Specify the input value corresponding to Argument name in Input value.
The specified input value is entered in the argument of the Java program.
- Click OK button.
- Notes
- The input value of the argument is not set automatically if the mapping line is set in the mapping viewer after setting the transformation function in the Custom dialog box. Specify again in Input value the input value corresponding to Argument name in the Custom dialog box.
- Invoke the custom function from the information of the method selected in the Choose transformation function dialog box. Even if the contents of the transformation function definition file change after selecting the method in the Choose transformation function dialog box, the change is not reflected in information of the method for invoking from the custom function. To reflect the changes of the transformation function definition file to the custom function, select the transformation function again.
- If the following setting contents do not match, an error occurs while executing the custom function but not while validating the business process. Setting contents must always match.
- Setting contents of the transformation function definition file
- Setting contents of the custom function
- Contents of the packaged jar file
- To use multiple transformation function definition files, switch the transformation function definition files in the Settings dialog box and set the custom function. Switching the transformation function definition files does not affect a set custom function.
All Rights Reserved. Copyright (C) 2015, Hitachi, Ltd.