public void WorkingElevator_exit() {
            WorkingElevator_lastState = WorkingElevator_subState;
            switch (WorkingElevator_subState) {
                case EmergencyStopped:
                {
                    EmergencyStopped_exit();
                    WorkingElevator_lastState = EmergencyStopped;
                }
                break;
                case EmergencyMoving:
                {
                    EmergencyMoving_exit();
                    WorkingElevator_lastState = EmergencyMoving;
                }
                break;
                case EmergencyBaseLevel:
                {
                    EmergencyBaseLevel_exit();
                    WorkingElevator_lastState = EmergencyBaseLevel;
                }
                break;
                case Stopped:
                {
                    Stopped_exit();
                    WorkingElevator_lastState = Stopped;
                }
                break;
                case waitingForRequest:
                {
                    waitingForRequest_exit();
                    WorkingElevator_lastState = waitingForRequest;
                }
                break;
                case Finished:
                {
                    Finished_exit();
                    WorkingElevator_lastState = Finished;
                }
                break;
                case Moving:
                {
                    Moving_exit();
                    WorkingElevator_lastState = Moving;
                }
                break;
                default:
                    break;
            }
            WorkingElevator_subState = RiJNonState;
            WorkingElevatorExit();
        }