| 
 | bea Systems, Inc. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--examples.workflow.WorkflowExample
Workflow example. This example shows the use of a Business Smart Component that has a workflow associated to it The workflow states and transitions are modeled with Rational Rose. For this examples, we'll use the EBusinessSession Component. This component has a workflow that guides it through the different stages of an online e-business session. If you look at the Rose model file for the ebusiness.session package, you will find that EBusinessSessionWorkflow has a state diagram associated to it. The workflow logic can be implemented in any way you want; however, Theory Center provides a reference implementation. For the reference implementation, for each component with the BSC.Workflow stereotype, all the states and transitions in the Rose model are generated into a complete state machine by the SmartGenerator, so you can use it immediately, without any hand-coding of the workflow states or transitions. Please note that the SmartGenerator is NOT included in the JumpStart Kit. In this example, we also use the EBusinessSessionManager and show how a "manager" session bean can simplify the usage of an entity bean
EBusinessSession, 
EBusinessSessionManager, 
EBusinessSessionWorkflow, 
Workflow| Constructor Summary | |
| WorkflowExample() | |
| Method Summary | |
|  EBusinessSession | createGuestSession()This method creates a new guest session. | 
|  void | exitExample(java.lang.String message,
            java.lang.Exception e)Exit program, displaying the exception | 
|  Customer | findOrCreateCustomer(java.lang.String customerKey)Finds or Creates a customer with customerKey | 
| static javax.naming.Context | getInitialContext()Gets an initial context for the current user, password and url. | 
| static void | main(java.lang.String[] args)Main driver. | 
|  void | playWithWorkflow(EBusinessSession session)This method takes a guest session and moves it thru its workflow | 
|  void | run()This method runs the example. | 
| Methods inherited from class java.lang.Object | 
| clone, 
equals, 
finalize, 
getClass, 
hashCode, 
notify, 
notifyAll, 
toString, 
wait, 
wait, 
wait | 
| Constructor Detail | 
public WorkflowExample()
| Method Detail | 
public EBusinessSession createGuestSession()
public void exitExample(java.lang.String message,
                        java.lang.Exception e)
message - the exit messagee - the exception that was raisedpublic Customer findOrCreateCustomer(java.lang.String customerKey)
customerKey - the primary key for out customer
public static javax.naming.Context getInitialContext()
                                              throws java.lang.Exception
public static void main(java.lang.String[] args)
public void playWithWorkflow(EBusinessSession session)
session - the guest EBusinesSessionpublic void run()
EBusinessSession, 
EBusinessSessionManager, 
Workflow| 
 | bea Systems, Inc. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||