Source for file Condition.php

Documentation is available at Condition.php

  1. <?php
  2. /**
  3.  * This file contains the interface XML_Query2XML_Callback.
  4.  *
  5.  * PHP version 5
  6.  *
  7.  * @category  XML
  8.  * @package   XML_Query2XML
  9.  * @author    Lukas Feiler <lukas.feiler@lukasfeiler.com>
  10.  * @copyright 2009 Lukas Feiler
  11.  * @license   http://www.gnu.org/copyleft/lesser.html  LGPL Version 2.1
  12.  * @version   CVS: $Id: Condition.php 309898 2011-04-02 17:38:08Z lukasfeiler $
  13.  * @link      http://pear.php.net/package/XML_Query2XML
  14.  */
  15.  
  16. /**
  17.  * XML_Query2XML_Data_Condition extends the class
  18.  * XML_Query2XML_Data_Processor.
  19.  */
  20. require_once 'XML/Query2XML/Data/Processor.php';
  21.  
  22. /**
  23.  * Abstract class extended by all Data Condition Classes.
  24.  * Such classes allow the implementation of a condition as to
  25.  * whether the return value of execute() is to be used.
  26.  *
  27.  * @category  XML
  28.  * @package   XML_Query2XML
  29.  * @author    Lukas Feiler <lukas.feiler@lukasfeiler.com>
  30.  * @copyright 2009 Lukas Feiler
  31.  * @license   http://www.gnu.org/copyleft/lesser.html  LGPL Version 2.1
  32.  * @version   Release: 1.7.2
  33.  * @link      http://pear.php.net/package/XML_Query2XML
  34.  * @since     Release 1.7.1RC1
  35.  */
  36. {
  37.     /**
  38.      * Returns a boolean value indicating whether the return value of execute()
  39.      * is to be used.
  40.      *
  41.      * @param mixed $value The return value of execute()
  42.      *
  43.      * @return boolean 
  44.      */
  45.     abstract public function evaluateCondition($value);
  46.     
  47.     /**
  48.      * Called by XML_Query2XML for every record in the result set.
  49.      *
  50.      * @param array $record An associative array.
  51.      *
  52.      * @return mixed Whatever is returned by the pre-processor.
  53.      * @throws XML_Query2XML_ConfigException Bubbles up if no
  54.      *                                        pre-processor was set.
  55.      */
  56.     public function execute(array $record)
  57.     {
  58.         return $this->runPreProcessor($record);
  59.     }
  60. }
  61. ?>

Documentation generated on Sun, 03 Apr 2011 13:13:07 +0200 by phpDocumentor 1.4.1