HTML_Menu
[ class tree: HTML_Menu ] [ index: HTML_Menu ] [ all elements ]

Source for file Renderer.php

Documentation is available at Renderer.php

  1. <?php
  2. //
  3. // +----------------------------------------------------------------------+
  4. // | PHP Version 4                                                        |
  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 <avb@php.net>                                  |
  17. // +----------------------------------------------------------------------+
  18. //
  19. // $Id: Renderer.php,v 1.4 2004/01/13 15:53:43 avb Exp $
  20. //
  21.  
  22. /**
  23.  * An abstract base class for HTML_Menu renderers
  24.  *
  25.  * @package  HTML_Menu
  26.  * @version  $Revision: 1.4 $
  27.  * @author   Alexey Borzov <avb@php.net>
  28.  * @abstract
  29.  */
  30. {
  31.    /**
  32.     * Type of the menu being rendered
  33.     * @var string 
  34.     */
  35.     var $_menuType;
  36.  
  37.    /**
  38.     * Sets the type of the menu being rendered.
  39.     *
  40.     * This method will throw an error if the renderer is not designed
  41.     * to render a specific menu type.
  42.     *
  43.     * @access public
  44.     * @param  string menu type
  45.     * @throws PEAR_Error
  46.     */
  47.     function setMenuType($menuType)
  48.     {
  49.         $this->_menuType $menuType;
  50.     }
  51.  
  52.  
  53.    /**
  54.     * Finish the menu
  55.     *
  56.     * @access public
  57.     * @param  int    current depth in the tree structure
  58.     */
  59.     function finishMenu($level)
  60.     {
  61.     }
  62.  
  63.  
  64.    /**
  65.     * Finish the tree level (for types 'tree' and 'sitemap')
  66.     *  
  67.     * @access public
  68.     * @param  int    current depth in the tree structure
  69.     */
  70.     function finishLevel($level)
  71.     {
  72.     }
  73.  
  74.  
  75.    /**
  76.     * Finish the row in the menu
  77.     *
  78.     * @access public
  79.     * @param  int    current depth in the tree structure
  80.     */
  81.     function finishRow($level)
  82.     {
  83.     }
  84.  
  85.  
  86.    /**
  87.     * Renders the element of the menu
  88.     *
  89.     * @access public
  90.     * @param array   Element being rendered
  91.     * @param int     Current depth in the tree structure
  92.     * @param int     Type of the element (one of HTML_MENU_ENTRY_* constants)
  93.     */
  94.     function renderEntry($node$level$type)
  95.     {
  96.     }
  97. }
  98.  
  99. ?>

Documentation generated on Mon, 11 Mar 2019 14:46:21 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.