You are here

function rules_item_type_invoke in Rules 6

Invoke an item type specific function, which will be item types base appended with _$op. The parameters given in $params will be passed to this function.

4 calls to rules_item_type_invoke()
rules_admin_form_import_submit in rules_admin/rules_admin.export.inc
rules_export_items in rules/rules.export.inc
Export all items given, where $export has to be an array of arrays keyed by item types, containing the items keyed by their names.
rules_item_delete in rules/rules.module
Deletes the given item from the database
rules_item_rule_set_export in rules/rules.export.inc
Item type callback: When exporting a rule set, add its rules to the export.

File

rules/rules.module, line 861
Rules engine module

Code

function rules_item_type_invoke($item_type, $op, $params = array()) {
  $info = rules_get_items($item_type);
  if (function_exists($function = $info['base'] . '_' . $op)) {
    return call_user_func_array($function, $params);
  }
}