* @copyright 2004 by http://wombat.exit0.net * @package wombatSite * @subpackage factory */ /** * creator class * * implement specialized create function. * * @version 1.0.1 */ class wbFactory_patSession { /** * special creator for patSession * * @static * @access private * @param array $params mixed parameter to modify the creation process * @return object $obj reference to the created object * @see create() */ function &create( &$params ) { $options = array( 'empty-referer' => 'allow', 'security' => 'fix_ip,fix_browser', ); $container = 'Native'; if( wbFactory::getParam( 'debugMode' ) !== 'Html' ) { $container = 'Cli'; } $obj =& patSession::singleton( 'wombat', $container, $options ); if( $obj->getState() !== 'active' ) { wbDebugger::addMsg( WBSITE_DEBUG_SECTION, 'Restarted session, because of session state: ' . $obj->getState(), 'Session' ); $obj->restart(); } return $obj; } } ?>