Source for file interface.php

Documentation is available at interface.php

  1. <?php
  2. /**
  3.  * @package     Joomla.Platform
  4.  * @subpackage  Observer
  5.  *
  6.  * @copyright   Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
  7.  * @license     GNU General Public License version 2 or later; see LICENSE
  8.  */
  9.  
  10. defined('JPATH_PLATFORM'or die;
  11.  
  12. /**
  13.  * Observer updater pattern implementation for Joomla
  14.  *
  15.  * @package     Joomla.Platform
  16.  * @subpackage  Observer
  17.  * @link        http://docs.joomla.org/JObserverUpdater
  18.  * @since       3.1.2
  19.  */
  20. {
  21.     /**
  22.      * Constructor
  23.      *
  24.      * @param   JObservableInterface  $observable  The observable subject object
  25.      *
  26.      * @since   3.1.2
  27.      */
  28.     public function __construct(JObservableInterface $observable);
  29.  
  30.     /**
  31.      * Adds an observer to the JObservableInterface instance updated by this
  32.      * This method can be called fron JObservableInterface::attachObserver
  33.      *
  34.      * @param   JObserverInterface  $observer  The observer object
  35.      *
  36.      * @return  void 
  37.      *
  38.      * @since   3.1.2
  39.      */
  40.     public function attachObserver(JObserverInterface $observer);
  41.  
  42.     /**
  43.      * Call all observers for $event with $params
  44.      *
  45.      * @param   string  $event   Event name (function name in observer)
  46.      * @param   array   $params  Params of event (params in observer function)
  47.      *
  48.      * @return  void 
  49.      *
  50.      * @since   3.1.2
  51.      */
  52.     public function update($event$params);
  53.  
  54.     /**
  55.      * Enable/Disable calling of observers (this is useful when calling parent:: function
  56.      *
  57.      * @param   boolean  $enabled  Enable (true) or Disable (false) the observer events
  58.      *
  59.      * @return  boolean  Returns old state
  60.      *
  61.      * @since   3.1.2
  62.      */
  63.     public function doCallObservers($enabled);
  64. }

Documentation generated on Tue, 19 Nov 2013 15:05:50 +0100 by phpDocumentor 1.4.3