Adding a snippet to assign the getQuoteInput variable

Follow these steps to add a snippet to assign the getQuoteInput variable to the PortfolioEvaluatorProcess process:
  1. Switch to the PortfolioEvaluatorProcess editor.
  2. Click the Snippet icon on the palette.
  3. Click the WhileLoop figure WhileLoop. The Snippet figure Snippet was added.
  4. Switch to the Properties view.
  5. In the details section, click the Description tab.
  6. In the Display Name field, type Assign getQuoteInput. The Name field is set to AssigngetQuoteInput.
  7. In the details section, click the Details tab.
  8. Add the existing InputVariable variable to the canvas and drill into InputVariable.inputStockPortfolio.stockInfoList.
  9. Add the existing counter variable to the canvas. type:List(java.util)
  10. Click the Java™... icon Java icon on the palette. The Select a Java Visual Snippet window opens.
  11. In the Specify a type (? = any character, * = any String) field, type java.util.List.
  12. Click List.
  13. Click get(int).
  14. Click OK.
  15. Click the canvas to add the activity. type:List(java.util)
  16. Add the existing stockInfo variable to the canvas.
  17. Connect the InputVariable.inputStockPortfolio.stockInfoList figure to the get figure
  18. Connect the counter figure to the get figure.
  19. Connect the get figure to the stockInfo figure. type:List(java.util)
  20. Add the existing stockInfo variable to the canvas and drill into stockInfo.symbol. type:List(java.util).
  21. Add the existing getQuoteInput variable to the canvas.
  22. Connect the stockInfo.symbol figure to the getQuoteInput figure.

Feedback
(C) Copyright IBM Corporation 2005. All Rights Reserved.