<?php
/**
 * JComments Settings Table ETL for #__jcomments_settings
 * 
 * @version 2.0
 * @package Migrator
 * @author Sergey M. Litvinov (smart@joomlatune.ru)
 * @copyright (C) 2008-2009 by Sergey M. Litvinov (http://www.joomlatune.ru)
 * @license GNU/GPL: http://www.gnu.org/copyleft/gpl.html
 */

class JComments_Settings_ETL extends ETLPlugin
{
	function getName()
	{
		return "JComments Settings ETL Plugin";
	}
	
	function getAssociatedTable()
	{
		return 'jcomments_settings';
	}
	
	function mapvalues( $key, $value )
	{
		switch ($key) {
			default:
				return $value;
				break;
		}
	}

	function getSQLPrologue()
	{
		$ret = <<<EOT

CREATE TABLE IF NOT EXISTS `#__jcomments_settings` (
`component` VARCHAR(50) NOT NULL DEFAULT '',
`lang` VARCHAR(20) NOT NULL DEFAULT '',
`name` VARCHAR(50) NOT NULL DEFAULT '',
`value` TEXT NOT NULL DEFAULT '',
PRIMARY KEY  (`component`, `lang`, `name`)
) TYPE=MyISAM CHARACTER SET `utf8` COLLATE `utf8_general_ci`;
    
EOT;
        return $ret;
    }
}
?>