<?php /** * API 文件基础文件 * * @package api * @subpackage ./ * @author 谢<*****@*****.**> */ /* 配置 API 目录 */ if (!defined('XCORE_API_PATH')) { define('XCORE_API_PATH', dirname(dirname(__FILE__))); } require_once XCORE_API_PATH . '/static/xstatic.class.php'; function __autoload($className) { xstatic::autoload($className); } xstatic::setAlias('orm', XCORE_API_PATH . '/orm'); xstatic::setAlias('nosql', XCORE_API_PATH . '/nosql'); xstatic::setAlias('factory', XCORE_API_PATH . '/factory'); /* use \orm\Mysql_DB as MySQL_DB; use \nosql\Redis_Cache as Redis_DB; use \nosql\Mongodb as Mongodb; use \factory\XFactory as XFactory; */
<?php /** * API 文件基础文件 * * @package api * @subpackage ./ * @author 谢<*****@*****.**> */ /* 配置 API 目录 */ if (!defined('XCORE_API_PATH')) { define('XCORE_API_PATH', dirname(dirname(__FILE__)) . '/xcore'); } if (!defined('XLOGGER_API_PATH')) { define('XLOGGER_API_PATH', __DIR__); } /** * 加载必须文件 */ require_once XCORE_API_PATH . '/base.inc.php'; xstatic::setAlias('xlogger', XLOGGER_API_PATH); /* use xlogger\module\XLogger_Redis as XLogger_Redis; use xlogger\module\XLogger_File as XLogger_File; use xlogger\module\XLogger_Mongodb as XLogger_Mongodb; */ use xlogger\module\XLogger;