示例#1
0
                protected internal override void TimeoutTransition(Events_ReceiveFSMContext context)
                {
                    Events_ReceiveFSM ctxt = context.Owner;


#if TRACE
                    Trace.WriteLine(
                        "TRANSITION   : Events_ReceiveFSM_SM.Receiving_Ready.TimeoutTransition()");
#endif

                    Events_ReceiveFSMState endState = context.State;

                    context.ClearState();

                    try
                    {
                        ctxt.cancelEventAction();
                        ctxt.SendAction("ConfirmEventRequest");
                        ctxt.stopEventTimerAction();
                    }
                    finally
                    {
                        context.State = endState;
                    }

                    return;
                }
示例#2
0
                protected internal override void ReceiveTransition(Events_ReceiveFSMContext context, QueryEvents msg, Receive.Body.ReceiveRec transportData)
                {
                    Events_ReceiveFSM ctxt = context.Owner;


#if TRACE
                    Trace.WriteLine(
                        "TRANSITION   : Events_ReceiveFSM_SM.Receiving_Ready.ReceiveTransition(, QueryEvents msg, Receive.Body.ReceiveRec transportData)");
#endif

                    Events_ReceiveFSMState endState = context.State;

                    context.ClearState();

                    try
                    {
                        ctxt.SendAction("ReportEvents", msg, transportData);
                    }
                    finally
                    {
                        context.State = endState;
                    }

                    return;
                }
示例#3
0
                protected internal override void EventOccurredTransition(Events_ReceiveFSMContext context)
                {
                    Events_ReceiveFSM ctxt = context.Owner;


#if TRACE
                    Trace.WriteLine(
                        "TRANSITION   : Events_ReceiveFSM_SM.Receiving_Ready.EventOccurredTransition()");
#endif

                    if (ctxt.eventExists())
                    {
                        Events_ReceiveFSMState endState = context.State;

                        context.ClearState();

                        try
                        {
                            ctxt.sendEventAction();
                        }
                        finally
                        {
                            context.State = endState;
                        }
                    }
                    else
                    {
                        base.EventOccurredTransition(context);
                    }

                    return;
                }
示例#4
0
                protected internal override void ReceiveTransition(Events_ReceiveFSMContext context, UpdateEvent msg, Receive.Body.ReceiveRec transportData)
                {
                    Events_ReceiveFSM ctxt = context.Owner;


#if TRACE
                    Trace.WriteLine(
                        "TRANSITION   : Events_ReceiveFSM_SM.Receiving_Ready.ReceiveTransition(, UpdateEvent msg, Receive.Body.ReceiveRec transportData)");
#endif

                    if (ctxt.isSupported(msg) && ctxt.eventExists(msg))
                    {
                        Events_ReceiveFSMState endState = context.State;

                        context.ClearState();

                        try
                        {
                            ctxt.updateEventAction(msg);
                            ctxt.SendAction("ConfirmEventRequest", msg, transportData);
                            ctxt.resetEventTimerAction();
                        }
                        finally
                        {
                            context.State = endState;
                        }
                    }
                    else if (!ctxt.isSupported(msg) || !ctxt.eventExists(msg))
                    {
                        Events_ReceiveFSMState endState = context.State;

                        context.ClearState();

                        try
                        {
                            ctxt.SendAction("RejectEventRequest", msg, transportData);
                        }
                        finally
                        {
                            context.State = endState;
                        }
                    }
                    else
                    {
                        base.ReceiveTransition(context, msg, transportData);
                    }

                    return;
                }