@classmethod
def mainloop(cls):
    cls._next_action = 'title'
    while (cls._next_action != cls.ACTION_EXIT):
        if (cls._next_action == cls.ACTION_TITLE):
            cls._next_action = cls.ACTION_NEW_WORDS
            cls.title()
        elif (cls._next_action == cls.ACTION_NEW_WORDS):
            cls._next_action = cls.ACTION_INTRO_TEXT
            cls.new_words()
            CLIOutput.empty_line(1)
            CLIUserInput.wait_for_enter()
        elif (cls._next_action == cls.ACTION_INTRO_TEXT):
            cls._next_action = cls.ACTION_SAMPLE_SENTENCES
            cls.intro_text()
            CLIOutput.empty_line(1)
            CLIUserInput.wait_for_enter()
        elif (cls._next_action == cls.ACTION_SAMPLE_SENTENCES):
            cls._next_action = cls.ACTION_DEFINITIONS
            cls.sample_sentences()
        elif (cls._next_action == cls.ACTION_DEFINITIONS):
            cls._next_action = cls.ACTION_MATCHING
            cls.definitions()
        elif (cls._next_action == cls.ACTION_MATCHING):
            cls._next_action = cls.ACTION_OTHER_NEW_WORDS
            cls.matching()
        elif (cls._next_action == cls.ACTION_OTHER_NEW_WORDS):
            cls._next_action = cls.ACTION_EXIT
            cls.other_new_words()
        else:
            raise KeyError('Unknown action request.')
@classmethod
def mainloop(cls):
    cls._next_action = 'title'
    while (cls._next_action != cls.ACTION_EXIT):
        if (cls._next_action == cls.ACTION_TITLE):
            cls._next_action = cls.ACTION_NEW_WORDS
            cls.title()
        elif (cls._next_action == cls.ACTION_NEW_WORDS):
            cls._next_action = cls.ACTION_INTRO_TEXT
            cls.new_words()
            CLIOutput.empty_line(1)
            CLIUserInput.wait_for_enter()
        elif (cls._next_action == cls.ACTION_INTRO_TEXT):
            cls._next_action = cls.ACTION_SAMPLE_SENTENCES
            cls.intro_text()
            CLIOutput.empty_line(1)
            CLIUserInput.wait_for_enter()
        elif (cls._next_action == cls.ACTION_SAMPLE_SENTENCES):
            cls._next_action = cls.ACTION_DEFINITIONS
            cls.sample_sentences()
        elif (cls._next_action == cls.ACTION_DEFINITIONS):
            cls._next_action = cls.ACTION_MATCHING
            cls.definitions()
        elif (cls._next_action == cls.ACTION_MATCHING):
            cls._next_action = cls.ACTION_OTHER_NEW_WORDS
            cls.matching()
        elif (cls._next_action == cls.ACTION_OTHER_NEW_WORDS):
            cls._next_action = cls.ACTION_EXIT
            cls.other_new_words()
        else:
            raise KeyError('Unknown action request.')