Quiz state diagrams
From MoodleDocs
Quizzes, quiz attempts, and questions can all go through a variety of states. The state each part is currently in affects how various things look, and what operations are available. Therefore, understanding the following diagram can make it a lot easier to understand what is going on in the quiz and question bank code.