예제 #1
0
 static void Main(string[] args)
 {
     int bankId = 1;
     StepContext stepContext = new StepContext(bankId);
     stepContext.InitTransactionModel("123456789", 1, "987654321", 1, 10000, "transfer money");
     worker = new Worker(stepContext);
     worker.OnStart += OnTransactionStart;
     worker.OnSuccess += OnTransactionSuccess;
     worker.OnFail += OnTransactionFail;
     worker.OnInprogress += OnTransactionInprogress;
     worker.Execute();
 }
예제 #2
0
        static void Main(string[] args)
        {
            int         bankId      = 1;
            StepContext stepContext = new StepContext(bankId);

            stepContext.InitTransactionModel("123456789", 1, "987654321", 1, 10000, "transfer money");
            worker               = new Worker(stepContext);
            worker.OnStart      += OnTransactionStart;
            worker.OnSuccess    += OnTransactionSuccess;
            worker.OnFail       += OnTransactionFail;
            worker.OnInprogress += OnTransactionInprogress;
            worker.Execute();
        }