The applications that use Elements are module-oriented. A module may already exist, it may have been created by another developer or we may simply decide not to overload it with any foreign logic. In such cases the remaining objects in the system have to be notified that a certain event has occurred (e.g. the Supply module may react to commodities enlisted to the warehouse, while it is managed by a separate, independent module).
Each object will notify the system about two main events - AddComplete and EditComplete – when a new entry is added or if an existing record has been edited, respectively. In addition to these events, the status system (described further below) adds the StatusChange event for each object, which possesses a status. These are all handled automatically by the platform. If, however, the given object or module has additional events, which are important for the remaining system modules, the developer can singlehandedly add as many events as are deemed necessary.
As far as each class ultimately inherits the basic class Object, it receives the FireEvent($sEventName, $arEventArgs) method which allows additional events to occur. The Object class is the one that identifies and calls all the classes that will be influenced by the event– each class is registered for all events it may be influenced by. It can be either specific for a single event of a single class or it may be a system-wide event. An example of the latter is the Log class, which monitors all AddComplete, EditComplete events and all deletions of records in the system, the interface accessed by a user and the actions used, in order to create a full-scale record of his/her activities in the system.