[ Index ]
 

Code source de phpMyVisites 2.3

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/libs/Html/QuickForm/ -> Renderer.php (source)

   1  <?php
   2  /* vim: set expandtab tabstop=4 shiftwidth=4: */
   3  // +----------------------------------------------------------------------+
   4  // | PHP version 4.0                                                      |
   5  // +----------------------------------------------------------------------+
   6  // | Copyright (c) 1997-2003 The PHP Group                                |
   7  // +----------------------------------------------------------------------+
   8  // | This source file is subject to version 2.0 of the PHP license,       |
   9  // | that is bundled with this package in the file LICENSE, and is        |
  10  // | available at through the world-wide-web at                           |
  11  // | http://www.php.net/license/2_02.txt.                                 |
  12  // | If you did not receive a copy of the PHP license and are unable to   |
  13  // | obtain it through the world-wide-web, please send a note to          |
  14  // | license@php.net so we can mail you a copy immediately.               |
  15  // +----------------------------------------------------------------------+
  16  // | Author: Alexey Borzov <borz_off@cs.msu.su>                           |
  17  // +----------------------------------------------------------------------+
  18  //
  19  // $Id: Renderer.php,v 1.1 2005/12/06 01:50:39 matthieu_ Exp $
  20  
  21  /**
  22   * An abstract base class for QuickForm renderers
  23   * 
  24   * The class implements a Visitor design pattern
  25   *
  26   * @abstract
  27   * @author Alexey Borzov <borz_off@cs.msu.su>
  28   */
  29  class HTML_QuickForm_Renderer
  30  {
  31     /**
  32      * Constructor
  33      *
  34      * @access public
  35      */
  36      function HTML_QuickForm_Renderer()
  37      {
  38      } // end constructor
  39  
  40     /**
  41      * Called when visiting a form, before processing any form elements
  42      *
  43      * @param    object    An HTML_QuickForm object being visited
  44      * @access   public
  45      * @return   void 
  46      * @abstract
  47      */
  48      function startForm(&$form)
  49      {
  50          return;
  51      } // end func startForm
  52  
  53     /**
  54      * Called when visiting a form, after processing all form elements
  55      * 
  56      * @param    object     An HTML_QuickForm object being visited
  57      * @access   public
  58      * @return   void 
  59      * @abstract
  60      */
  61      function finishForm(&$form)
  62      {
  63          return;
  64      } // end func finishForm
  65  
  66     /**
  67      * Called when visiting a header element
  68      *
  69      * @param    object     An HTML_QuickForm_header element being visited
  70      * @access   public
  71      * @return   void 
  72      * @abstract
  73      */
  74      function renderHeader(&$header)
  75      {
  76          return;
  77      } // end func renderHeader
  78  
  79     /**
  80      * Called when visiting an element
  81      *
  82      * @param    object     An HTML_QuickForm_element object being visited
  83      * @param    bool       Whether an element is required
  84      * @param    string     An error message associated with an element
  85      * @access   public
  86      * @return   void 
  87      * @abstract
  88      */
  89      function renderElement(&$element, $required, $error)
  90      {
  91          return;
  92      } // end func renderElement
  93  
  94     /**
  95      * Called when visiting a hidden element
  96      * 
  97      * @param    object     An HTML_QuickForm_hidden object being visited
  98      * @access   public
  99      * @return   void
 100      * @abstract 
 101      */
 102      function renderHidden(&$element)
 103      {
 104          return;
 105      } // end func renderHidden
 106  
 107     /**
 108      * Called when visiting a raw HTML/text pseudo-element
 109      * 
 110      * Seems that this should not be used when using a template-based renderer
 111      *
 112      * @param    object     An HTML_QuickForm_html element being visited
 113      * @access   public
 114      * @return   void 
 115      * @abstract
 116      */
 117      function renderHtml(&$data)
 118      {
 119          return;
 120      } // end func renderHtml
 121  
 122     /**
 123      * Called when visiting a group, before processing any group elements
 124      *
 125      * @param    object     An HTML_QuickForm_group object being visited
 126      * @param    bool       Whether a group is required
 127      * @param    string     An error message associated with a group
 128      * @access   public
 129      * @return   void 
 130      * @abstract
 131      */
 132      function startGroup(&$group, $required, $error)
 133      {
 134          return;
 135      } // end func startGroup
 136  
 137     /**
 138      * Called when visiting a group, after processing all group elements
 139      *
 140      * @param    object     An HTML_QuickForm_group object being visited
 141      * @access   public
 142      * @return   void 
 143      * @abstract
 144      */
 145      function finishGroup(&$group)
 146      {
 147          return;
 148      } // end func finishGroup
 149  } // end class HTML_QuickForm_Renderer
 150  ?>


Généré le : Mon Nov 26 14:10:01 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics