20 defined(
'XOOPS_ROOT_PATH') or die('Restricted access');
34 function __construct()
51 function getInstance()
54 if (!isset($instance)) {
56 $instance =
new $class();
67 static function load($name =
'file')
71 if (!class_exists(
'XoopsFolderHandler')) {
72 if (file_exists($folder = dirname(__FILE__) .
'/folder.php')) {
75 trigger_error(
'Require Item : ' . str_replace(XOOPS_ROOT_PATH,
'', $folder) .
' In File ' . __FILE__ .
' at Line ' . __LINE__, E_USER_WARNING);
82 if (!class_exists(
'XoopsFileHandler')) {
83 if (file_exists(
$file = dirname(__FILE__) .
'/file.php')) {
86 trigger_error(
'Require File : ' . str_replace(XOOPS_ROOT_PATH,
'',
$file) .
' In File ' . __FILE__ .
' at Line ' . __LINE__, E_USER_WARNING);
105 static function getHandler($name =
'file',
$path =
false, $create =
false, $mode = null)
109 $class =
'Xoops' . ucfirst($name) .
'Handler';
110 if (class_exists($class)) {
113 trigger_error(
'Class ' . $class .
' not exist in File ' . __FILE__ .
' at Line ' . __LINE__, E_USER_WARNING);