< Previous | Next >

Creating the business process implementation

Define the business logic of the application and generate the starting implementation for PortfolioEvaluatorProcess.

To generate the process implementation:
  1. Right-click the PortfolioEvaluatorProcess component and select Generate Implementation. The Generate Implementation window opens.
  2. Click New Folder. The New Folder window opens.
  3. In the Folder Name field, type com\emerged\stockportfolio\process and click OK. You will then see the window shown in the following figure:
    Generate Implementation window
  4. Click OK and the process editor opens, as shown below:
    Initial business process
As you can see, our business process has been created but it is far from complete.
Let's look at the new items displayed in the process editor:
  1. StockPortfolioInterface: This is the interface for the PortfolioEvaluatorProcess component. It defines a single request-response operation for our business process, called getStockPortfolioValue. This operation takes a StockPortfolioBO as an input and also as an output.
  2. StockQuotePortTypePartner: This reference of the PortfolioEvaluatorProcess component allows us to call the StockQuoteService component from the process to obtain stock quotes.
  3. Variables: The two variables, InputStockPortfolio and OutputStockPortfolio, were automatically created to save time, based on the input and output of the getStockPortfolioValue operation of StockPortfolioInterface.
  4. Receive and Reply: When the process is called, several things will happen:
    1. The Receive activity will get the input defined by the getStockPortfolioValue operation: a StockPortfolioBO.
    2. The StockPortfolioBO will then be stored in the InputStockPortfolio variable, to ensure that we can work with it within the process.
    3. In the later stages of our application, we will assign a StockPortfolioBO to the OutputStockPortfolio variable.
    4. When the process is nearly complete, the OutputStockPortfolio value will reach the Reply activity, which will return the StockPortfolioBO as the business process output.
Next, we will add several additional variables to the process so that we can work with several business objects within the process.

Feedback
(C) Copyright IBM Corporation 2005, 2007. All Rights Reserved.
< Previous | Next >