| [ Index ] |
PHP Cross Reference of Joomla 1.5.26 DE |
[Summary view] [Print] [Text view]
1 <?PHP 2 /** 3 * patTemplate Module base class 4 * 5 * $Id: Module.php 10381 2008-06-01 03:35:53Z pasamio $ 6 * 7 * The patTemplate_Module is the base class for all patTemplate 8 * modules like readers, dumpers, filters, etc. 9 * 10 * @package patTemplate 11 * @author Stephan Schmidt <schst@php.net> 12 */ 13 14 /** 15 * patTemplate Module base class 16 * 17 * $Id: Module.php 10381 2008-06-01 03:35:53Z pasamio $ 18 * 19 * The patTemplate_Module is the base class for all patTemplate 20 * modules like readers, dumpers, filters, etc. 21 * 22 * @abstract 23 * @package patTemplate 24 * @author Stephan Schmidt <schst@php.net> 25 * @abstract 26 */ 27 class patTemplate_Module 28 { 29 /** 30 * module name 31 * 32 * This has to be set in the final 33 * module classes. 34 * 35 * @access protected 36 * @var string 37 */ 38 var $_name = null; 39 40 /** 41 * module parameters 42 * 43 * @access protected 44 * @var array 45 */ 46 var $_params = array(); 47 48 /** 49 * get the name of the module 50 * 51 * @access public 52 * @return string name of the module 53 */ 54 function getName() 55 { 56 return $this->_name; 57 } 58 59 /** 60 * sets parameters of the module 61 * 62 * @access public 63 * @param array assoc array containing parameters 64 * @param boolean flag to indicate, whether previously set parameters should be cleared 65 */ 66 function setParams( $params, $clear = false ) 67 { 68 if( $clear === true ) 69 $this->_params = array(); 70 $this->_params = array_merge( $this->_params, $params ); 71 } 72 73 /** 74 * gets a parameter of the module 75 * 76 * @access public 77 * @param string name of the parameter 78 * @return mixed value of the parameter 79 */ 80 function getParam( $name ) 81 { 82 if( isset( $this->_params[$name] ) ) 83 return $this->_params[$name]; 84 return false; 85 } 86 } 87 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| Generated: Wed Mar 28 15:54:07 2012 | Cross-referenced by PHPXref 0.7.1 |