1. A non-transitory computer-readable medium that stores instructions executable by at least one processor, the computer-readable medium storing one or more instructions for: detecting an event thrown by a first state that is part of a representation having states and transitions, the event being thrown during a top-down processing of the representation; switching from the top-down processing of the representation to a bottom-up processing of the representation; determining that the event cannot be handled by the first state; and throwing the event to a second state that is part of the representation, the second state being a superstate of the first state.