diff --git a/dibi/dibi.php b/dibi/dibi.php index f0a9d90cf..6da6d835b 100644 --- a/dibi/dibi.php +++ b/dibi/dibi.php @@ -68,7 +68,7 @@ class FileNotFoundException extends IOException {} require_once dirname(__FILE__) . '/libs/DibiResult.php'; require_once dirname(__FILE__) . '/libs/DibiTranslator.php'; require_once dirname(__FILE__) . '/libs/DibiVariable.php'; -require_once dirname(__FILE__) . '/libs/DibiTable.php'; +require_once dirname(__FILE__) . '/libs/DibiTableX.php'; require_once dirname(__FILE__) . '/libs/DibiDataSource.php'; require_once dirname(__FILE__) . '/libs/DibiFluent.php'; require_once dirname(__FILE__) . '/libs/DibiDatabaseInfo.php'; @@ -111,7 +111,7 @@ class dibi /**#@+ * dibi version */ - const VERSION = '0.9'; + const VERSION = '1.0'; const REVISION = '$WCREV$ released on $WCDATE$'; /**#@-*/ diff --git a/dibi/libs/DibiProfiler.php b/dibi/libs/DibiProfiler.php index 7761c4b52..11ed77024 100644 --- a/dibi/libs/DibiProfiler.php +++ b/dibi/libs/DibiProfiler.php @@ -130,10 +130,10 @@ public function after($ticket, $res = NULL) $payload = function_exists('json_encode') ? json_encode($payload) : self::json_encode($payload); foreach (str_split($payload, 4990) as $num => $s) { $num++; - header("X-Wf-dibi-1-1-$num: |$s|\\"); // protocol-, structure-, plugin-, message-index + header("X-Wf-dibi-1-1-d$num: |$s|\\"); // protocol-, structure-, plugin-, message-index } - header("X-Wf-dibi-1-1-$num: |$s|"); - header("X-Wf-dibi-Index: $num"); + header("X-Wf-dibi-1-1-d$num: |$s|"); + header("X-Wf-dibi-Index: d$num"); } if ($this->file) { diff --git a/dibi/libs/DibiTable.php b/dibi/libs/DibiTableX.php similarity index 98% rename from dibi/libs/DibiTable.php rename to dibi/libs/DibiTableX.php index f03f865bd..6240b9c5a 100644 --- a/dibi/libs/DibiTable.php +++ b/dibi/libs/DibiTableX.php @@ -26,7 +26,7 @@ * @copyright Copyright (c) 2005, 2008 David Grudl * @package dibi */ -abstract class DibiTable extends DibiObject +abstract class DibiTableX extends DibiObject { /** @var string primary key mask */ public static $primaryMask = 'id'; @@ -411,3 +411,10 @@ public function __call($name, $args) } } + + + + +abstract class DibiTable extends DibiTableX +{ +} \ No newline at end of file diff --git a/examples/Nette/Debug.php b/examples/Nette/Debug.php index e704468bc..c50ecde67 100644 --- a/examples/Nette/Debug.php +++ b/examples/Nette/Debug.php @@ -50,7 +50,7 @@ function class Framework{const VERSION='0.8';const -REVISION='106 released on 2008/10/27 11:13:57';final +REVISION='107 released on 2008/10/29 20:40:23';final public function __construct(){throw @@ -80,8 +80,7 @@ class static$keysToHide=array('password','passwd','pass','pwd','creditcard','credit card','cc','pin');private static$colophons=array(array(__CLASS__,'getDefaultColophons'));private static$keyFilter=array();public -static$time;private -static$fireCounter;const +static$time;const LOG='LOG';const INFO='INFO';const WARN='WARN';const @@ -597,13 +596,13 @@ function fireLog($message,$priority=self::LOG,$label=NULL){if($message instanceof Exception){$priority='TRACE';$message=array('Class'=>get_class($message),'Message'=>$message->getMessage(),'File'=>$message->getFile(),'Line'=>$message->getLine(),'Trace'=>self::replaceObjects($message->getTrace()));}elseif($priority==='GROUP_START'){$label=$message;$message=NULL;}return -self::fireSend(1,array(array('Type'=>$priority,'Label'=>$label),$message));}private +self::fireSend(1,array(array('Type'=>$priority,'Label'=>$label),self::replaceObjects($message)));}private static function fireSend($index,$payload){if(headers_sent())return -FALSE;if(!self::$fireCounter){header('X-Wf-Protocol-nette: http://meta.wildfirehq.org/Protocol/JsonStream/0.2');header('X-Wf-nette-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.2.0');header('X-Wf-nette-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1');header('X-Wf-nette-Structure-2: http://meta.firephp.org/Wildfire/Structure/FirePHP/Dump/0.1');}$payload=json_encode($payload);foreach(str_split($payload,4990)as$s){$num=++self::$fireCounter;header("X-Wf-nette-$index-1-$num: |$s|\\");}header("X-Wf-nette-$index-1-$num: |$s|");header("X-Wf-nette-Index: $num");return +FALSE;header('X-Wf-Protocol-nette: http://meta.wildfirehq.org/Protocol/JsonStream/0.2');header('X-Wf-nette-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.2.0');if($index===1){header('X-Wf-nette-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1');}elseif($index===2){header('X-Wf-nette-Structure-2: http://meta.firephp.org/Wildfire/Structure/FirePHP/Dump/0.1');}$payload=json_encode($payload);static$counter;foreach(str_split($payload,4990)as$s){$num=++$counter;header("X-Wf-nette-$index-1-n$num: |$s|\\");}header("X-Wf-nette-$index-1-n$num: |$s|");header("X-Wf-nette-Index: n$num");return TRUE;}static private function -replaceObjects($val){foreach($val -as$k=>$v){if(is_object($v)){$val[$k]='object '.get_class($v).'';}elseif(is_array($v)){$val[$k]=self::replaceObjects($v);}}return$val;}}Debug::$html=PHP_SAPI!=='cli';Debug::$time=microtime(TRUE); \ No newline at end of file +replaceObjects($val){if(is_object($val)){return'object '.get_class($val).'';}elseif(is_array($val)){foreach($val +as$k=>$v){unset($val[$k]);$val[$k]=self::replaceObjects($v);}}return$val;}}Debug::$html=PHP_SAPI!=='cli';Debug::$time=microtime(TRUE); \ No newline at end of file diff --git a/examples/dibi.table.php b/examples/dibi.table.php index c06c921cd..b38161390 100644 --- a/examples/dibi.table.php +++ b/examples/dibi.table.php @@ -1,4 +1,4 @@ -