1 7 package com.inversoft.verge.mvc.test; 8 9 10 import com.inversoft.verge.mvc.controller.actionflow.ActionFlowAction; 11 12 13 21 public class RealLongTxnActionHandler { 22 23 public String handleStart(ActionFlowAction action) { 24 return "action1"; 25 } 26 27 public String handleAction1(ActionFlowAction action) throws InterruptedException { 28 Thread.sleep(5000); 29 System.out.println("Finished with action1 after 5 seconds"); 30 return "action2"; 31 } 32 33 public String handleAction2(ActionFlowAction action) throws InterruptedException { 34 Thread.sleep(5000); 35 System.out.println("Finished with action2 after 5 seconds"); 36 return "action3"; 37 } 38 39 public String handleAction3(ActionFlowAction action) { 40 System.out.println("Finished with action3. No delay"); 41 return "action4"; 42 } 43 44 public String handleAction4(ActionFlowAction action) { 45 System.out.println("Finished with action4. No delay"); 46 return "action5"; 47 } 48 49 public String handleAction5(ActionFlowAction action) throws InterruptedException { 50 Thread.sleep(5000); 51 System.out.println("Finished with action5 after 5 seconds"); 52 return "action6"; 53 } 54 55 public String handleAction6(ActionFlowAction action) throws InterruptedException { 56 Thread.sleep(5000); 57 System.out.println("Finished with action6 after 5 seconds"); 58 return "action7"; 59 } 60 } | Popular Tags |