-- This file is generated from Test.ump --

-- PLEASE DO NOT EDIT THIS CODE --
-- This code was generated using the UMPLE @UMPLE_VERSION@ modeling language! --


-- This defines a NuSMV module for BookingState --
MODULE BookingState

   -- This part declares state variables for the given NuSMV module --
   VAR
     state : { State_newBooking , State_seatAssigned , State_checkedIn , State_cancelled , State_completed };
     event : { ev_cancel , ev_cance , ev_checkIn , ev_assignSeat , ev_complete , ev_null };

   -- This part defines macros that summarize the transitions and guards (if any) of the given NuSMV module --
   DEFINE
     state_stable :=  !( event = ev_cance | event = ev_assignSeat | event = ev_cancel | event = ev_checkIn | event = ev_complete );
     t1 := event = ev_assignSeat & state = State_newBooking;
     t2 := event = ev_cancel & state = State_newBooking;
     t3 := event = ev_cancel & state = State_seatAssigned;
     t4 := event = ev_checkIn & state = State_seatAssigned;
     t5 := event = ev_cance & state = State_seatAssigned;
     t6 := event = ev_cancel & state = State_checkedIn;
     t7 := event = ev_complete & state = State_checkedIn;

   -- This part defines logic for the assignment of values to state variable "state" of this NuSMV module --
   ASSIGN
     init( state ) := State_newBooking;
     next( state ) := case
       t1 : State_seatAssigned;
       t4 : State_checkedIn;
       t2 | t5 | t3 | t6 : State_cancelled;
       t7 : State_completed;
       TRUE : state;
     esac;

   -- This part defines logic for the assignment of values to state variable "event" of this NuSMV module --
   ASSIGN
     init( event ) := ev_null;
     next( event ) := case
       state_stable : { ev_cancel , ev_cance , ev_checkIn , ev_assignSeat , ev_complete };
       TRUE : ev_null;
     esac;

-- This defines a NuSMV module for BookingState_Machine --
MODULE BookingState_Machine

   -- This part declares state variables for the given NuSMV module --
   VAR
     bookingState : BookingState;

-- This defines a NuSMV module for main --
MODULE main

   -- This part declares state variables for the given NuSMV module --
   VAR
     bookingState_Machine : BookingState_Machine;

   -- The following properties are specified to certify that non-symbolic state(s) of this model is (or are) reachable. 
   CTLSPEC   EF( bookingState_Machine.bookingState.state = State_newBooking )
   CTLSPEC   EF( bookingState_Machine.bookingState.state = State_seatAssigned )
   CTLSPEC   EF( bookingState_Machine.bookingState.state = State_checkedIn )
   CTLSPEC   EF( bookingState_Machine.bookingState.state = State_cancelled )
   CTLSPEC   EF( bookingState_Machine.bookingState.state = State_completed )