Condition: - Here the rule deciphers whether the action should be executed as specified the action will automatically trigger. Action: - the action can either be a sequence of SQL statements but it could basically be any action taken by the database or even the execution from the database, of an external application. Events Events describe situations to which a reaction must be shown Events are objects, therefore they belong to event classes Event classes can be organized in hierarchies (inheritance) Events can be primitive or composite Primitive events Method invocation - Modification and/or retrieval of object values - General-purpose methods - Database methods (e.g. transaction operations) Time events - Absolute (e.g. 1 Jan 2000 at 12:00) - Relative (e.g. 10 min after stock market closing time) - Periodic intervals (e.g. every 10 minutes) Application-specific or user-defined events; they must be explicitly raised by the application or the user An event can be raised before or after method invocation E.g. before accessing an object a security rule is checked After updating the salary attribute of an employee object the average salary of all employees is re-calculated ECA rules are implemented as a "detour" from normal method execution Detection of Events
Condition: - Here the rule deciphers whether the action should be executed as specified the action will automatically trigger. Action: - the action can either be a sequence of SQL statements but it could basically be any action taken by the database or even the execution from the database, of an external application. Events Events describe situations to which a reaction must be shown Events are objects, therefore they belong to event classes Event classes can be organized in hierarchies (inheritance) Events can be primitive or composite Primitive events Method invocation - Modification and/or retrieval of object values - General-purpose methods - Database methods (e.g. transaction operations) Time events - Absolute (e.g. 1 Jan 2000 at 12:00) - Relative (e.g. 10 min after stock market closing time) - Periodic intervals (e.g. every 10 minutes) Application-specific or user-defined events; they must be explicitly raised by the application or the user An event can be raised before or after method invocation E.g. before accessing an object a security rule is checked After updating the salary attribute of an employee object the average salary of all employees is re-calculated ECA rules are implemented as a "detour" from normal method execution Detection of Events