<?php
/**
* *** BEGIN LICENSE BLOCK *****
*
* This file is part of FirePHP (http://www.firephp.org/).
*
* Software License Agreement (New BSD License)
*
* Copyright (c) 2006-2010, Christoph Dorn
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* * Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* * Neither the name of Christoph Dorn nor the names of its
* contributors may be used to endorse or promote products derived from this
* software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* ***** END LICENSE BLOCK *****
*
* @copyright Copyright (C) 2007-2009 Christoph Dorn
* @author Christoph Dorn <christoph@christophdorn.com>
* @license http://www.opensource.org/licenses/bsd-license.php
* @package FirePHPCore
*/
/**
* @see http://code.google.com/p/firephp/issues/detail?id=112
*/
if (!defined('E_STRICT')) {
define('E_STRICT', 2048);
}
if (!defined('E_RECOVERABLE_ERROR')) {
define('E_RECOVERABLE_ERROR', 4096);
}
if (!defined('E_DEPRECATED')) {
define('E_DEPRECATED', 8192);
}
if (!defined('E_USER_DEPRECATED')) {
define('E_USER_DEPRECATED', 16384);
}
/**
* Sends the given data to the FirePHP Firefox Extension.
* The data can be displayed in the Firebug Console or in the
* "Server" request tab.
*
* For more information see: http://www.firephp.org/
*
* @copyright Copyright (C) 2007-2009 Christoph Dorn
* @author Christoph Dorn <christoph@christophdorn.com>
* @license http://www.opensource.org/licenses/bsd-license.php
* @package FirePHPCore
*/
class FirePHP {
/**
* FirePHP version
*
* @var string
*/
const VERSION = '0.3'; // @pinf replace '0.3' with '%%package.version%%'
/**
* Firebug LOG level
*
* Logs a message to firebug console.
*
* @var string
*/
const LOG = 'LOG';
/**
* Firebug INFO level
*
* Logs a message to firebug console and displays an info icon before the message.
*
* @var string
*/
const INFO = 'INFO';
/**
* Firebug WARN level
*
* Logs a message to firebug console, displays an warning icon before the message and colors the line turquoise.
*
* @var string
*/
const WARN = 'WARN';
/**
* Firebug ERROR level
*
* Logs a message to firebug console, displays an error icon before the message and colors the line yellow. Also increments the firebug error count.
*
* @var string
*/
const ERROR = 'ERROR';
/**
* Dumps a variable to firebug's server panel
*
* @var string
*/
const DUMP = 'DUMP';
/**
* Displays a stack trace in firebug console
*
* @var string
*/
const TRACE = 'TRACE';
/**
* Displays an exception in firebug console
*
* Increments the firebug error count.
*
* @var string
*/
const EXCEPTION = 'EXCEPTION';
/**
* Displays an table in firebug console
*
* @var string
*/
const TABLE = 'TABLE';
/**
* Starts a group in firebug console
*
* @var string
*/
const GROUP_START = 'GROUP_START';
/**
* Ends a group in firebug console
*
* @var string
*/
const GROUP_END = 'GROUP_END';
/**
* Singleton instance of FirePHP
*
* @var FirePHP
*/
protected static $instance = null;
/**
* Flag whether we are logging from within the exception handler
*
* @var boolean
*/
protected $inExceptionHandler = false;
/**
* Flag whether to throw PHP errors that have been converted to ErrorExceptions
*
* @var boolean
*/
protected $throwErrorExceptions = true;
/**
* Flag whether to convert PHP assertion errors to Exceptions
*
* @var boolean
*/
protected $convertAssertionErrorsToExceptions = true;
/**
* Flag whether to throw PHP assertion errors that have been converted to Exceptions
*
* @var boolean
*/
protected $throwAssertionExceptions = false;
/**
* Wildfire protocol message index
*
* @var int
*/
protected $messageIndex = 1;
/**
* Options for the library
*
* @var array
*/
protected $options = array('maxDepth' => 10,
'maxObjectDepth' => 5,
'maxArrayDepth' => 5,
'useNativeJsonEncode' => true,
'includeLineNumbers' => true);
/**
* Filters used to exclude object members when encoding
*
* @var array
*/
protected $objectFilters = array(
'firephp' => array('objectStack', 'instance', 'json_objectStack'),
'firephp_test_class' => array('objectStack', 'instance', 'json_objectStack')
);
/**
* A stack of objects used to detect recursion during object encoding
*
* @var object
*/
protected $objectStack = array();
/**
* Flag to enable/disable logging
*
* @var boolean
*/
protected $enabled = true;
/**
* The insight console to log to if applicable
*
* @var object
*/
protected $logToInsightConsole = null;
/**
* When the object gets serialized only include specific object members.
*
* @return array
*/
public function __sleep()
{
return array('options','objectFilters','enabled');
}
/**
* Gets singleton instance of FirePHP
*
* @param boolean $AutoCreate
* @return FirePHP
*/
public static function getInstance($AutoCreate = false)
{
if ($AutoCreate===true && !self::$instance) {
self::init();
}
return self::$instance;
}
/**
* Creates FirePHP object and stores it for singleton access
*
* @return FirePHP
*/
public static function init()
{
return self::setInstance(new self());
}
/**
* Set the instance of the FirePHP singleton
*
* @param FirePHP $instance The FirePHP object instance
* @return FirePHP
*/
public static function setInstance($instance)
{
return self::$instance = $instance;
}
/**
* Set an Insight console to direct all logging calls to
*
* @param object $console The console object to log to
* @return void
*/
没有合适的资源?快使用搜索试试~ 我知道了~
基于PHP的Leaps Framework 轻量级php开发框架.zip
共40个文件
php:37个
sess_qhpi0ver6kmvgghke2nnmcg111:1个
log:1个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 62 浏览量
2023-07-20
23:30:42
上传
评论
收藏 76KB ZIP 举报
温馨提示
基于PHP的Leaps Framework 轻量级php开发框架.zip
资源推荐
资源详情
资源评论
收起资源包目录
基于PHP的Leaps Framework 轻量级php开发框架.zip (40个子文件)
132684863646347779
application
cache
log
ErrorLog.log 0B
views
default
zh-cn
content
index.php 2KB
session
sess_qhpi0ver6kmvgghke2nnmcg111 0B
source
language
zh-cn
en
libraries
helpers
global.func.php 1KB
autoload
model
content_model.class.php 1KB
hooks
Myclass.php 945B
config
cache.php 957B
database.php 1KB
hook.php 2KB
core.php 3KB
views
default
content
index.html 2KB
apps
content
IndexController.php 1KB
config
cache.php 957B
database.php 1KB
hook.php 2KB
core.php 3KB
index.php 1KB
Leaps
framework.php 11KB
template
exception.tpl.php 2KB
trace.tpl.php 390B
language
zh-cn
leaps.lang.php 2KB
en
libraries
FirePHP.class.php 66KB
cache
cache_file.class.php 4KB
cache_sae.class.php 2KB
helpers
path.func.php 895B
number.func.php 3KB
security.func.php 899B
page.func.php 5KB
database
mysql.class.php 13KB
core
class
param.class.php 4KB
router.class.php 4KB
cache.class.php 3KB
cookie.class.php 2KB
db_factory.class.php 3KB
model.class.php 8KB
view.class.php 6KB
application.class.php 3KB
function
global.func.php 26KB
queue
vendor
fonts
session
session_sae.class.php 967B
session_file.class.php 1KB
共 40 条
- 1
资源评论
助力毕业
- 粉丝: 2177
- 资源: 5126
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功