Abstract:
Disclosed are apparatus and methods for executing software applications with an actual environment. Handlers for a software application are registered. Each handler can be executed upon receiving an indication of a triggering event. A determination is made that a triggering event for the software application has occurred. In response to the triggering event: a handler environment for the triggering event is determined based on the actual environment, triggered handlers of the registered handlers are determined to be executed, at least a respective portion of the handler environment is made available to each triggered handler, executing the triggered handlers, where at least one triggered handler updates its respective portion of the handler environment during execution, determining an updated-handler environment based on the handler environment and the portions of the handler environments after execution of the triggered handlers, and updating the actual environment based on the updated-handler environment.