CoreFiles by mySites.guru
Module.php87 lines, 1,742 bytes, from Joomla_1.5.0-Stable-Full_Package.zip
Raw History Compare with 1.0.15
md5
8344aef0b93ceb9882ac5bca325a50b3
sha1
501d1696ca5bf4cf5700b9f43d1f1d16e5c4acdb
sha256
2dd90fe489202ee1636714501311f0a1f7a963e2bcffca5d736d6e8f53477200
<?PHP
/**
 * patTemplate Module base class
 *
 * $Id: Module.php 8287 2007-08-01 08:38:59Z eddieajau $
 *
 * The patTemplate_Module is the base class for all patTemplate
 * modules like readers, dumpers, filters, etc.
 *
 * @package		patTemplate
 * @author		Stephan Schmidt <[email protected]>
 */

/**
 * patTemplate Module base class
 *
 * $Id: Module.php 8287 2007-08-01 08:38:59Z eddieajau $
 *
 * The patTemplate_Module is the base class for all patTemplate
 * modules like readers, dumpers, filters, etc.
 *
 * @abstract
 * @package		patTemplate
 * @author		Stephan Schmidt <[email protected]>
 * @abstract
 */
class patTemplate_Module
{
	/**
	* module name
	*
	* This has to be set in the final
	* module classes.
	*
	* @access	protected
	* @var		string
	*/
	var	$_name = null;

	/**
	* module parameters
	*
	* @access	protected
	* @var		array
	*/
	var	$_params = array();

	/**
	* get the name of the module
	*
	* @access	public
	* @return	string	name of the module
	*/
	function getName()
	{
		return $this->_name;
	}

	/**
	* sets parameters of the module
	*
	* @access	public
	* @param	array	assoc array containing parameters
	* @param	boolean	flag to indicate, whether previously set parameters should be cleared
	*/
	function setParams( $params, $clear = false )
	{
		if( $clear === true )
			$this->_params = array();
		$this->_params = array_merge( $this->_params, $params );
	}

	/**
	* gets a parameter of the module
	*
	* @access	public
	* @param	string	name of the parameter
	* @return	mixed	value of the parameter
	*/
	function getParam( $name )
	{
		if( isset( $this->_params[$name] ) )
			return $this->_params[$name];
		return false;
	}
}
?>

The same content is in 4 releases, Joomla 1.5.0 to 1.5.3. See them all, or every version of this file.