DB_NestedSet::addListener

DB_NestedSet::addListener() – Add an event listener

Synopsis

require_once 'DB/NestedSet.php';

string DB_NestedSet::addListener ( string $event , &$listener , string $listener )

Description

Adds an event listener and returns an ID for it Known events are
 nodeCreate
 nodeDelete
 nodeUpdate
 nodeCopy
 nodeLoad

Parameter

string $event

The event name

string $listener

The listener object

Throws

throws no exceptions thrown

Note

This function can not be called statically.

Example

Add Listener

<?php
require_once('DB/NestedSet.php');
    
$nestedSet =& DB_NestedSet::factory('DB'$dsn$params);
    
$nestedSet->AddListener("nodeCreate""listener");
?>
Introduction to DB_NestedSet (Previous) apiVersion (Next)
Last updated: Sat, 16 Feb 2019 — Download Documentation
Do you think that something on this page is wrong? Please file a bug report.
View this page in:
  • English

User Notes:

There are no user contributed notes for this page.