Changeset 3155 for trunk/lib/Doctrine.php
- Timestamp:
- 11/14/07 13:13:23 (14 months ago)
- Files:
-
- 1 modified
-
trunk/lib/Doctrine.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/lib/Doctrine.php
r3138 r3155 977 977 * @param mixed $var a variable of any type 978 978 * @param boolean $output whether to output the content 979 * @param string $indent indention string 979 980 * @return void|string 980 981 */ 981 public static function dump($var, $output = true )982 public static function dump($var, $output = true, $indent = "") 982 983 { 983 984 $ret = array(); … … 985 986 case 'array': 986 987 $ret[] = 'Array('; 988 $indent .= " "; 987 989 foreach ($var as $k => $v) { 988 $ret[] = $k . ' : ' . self::dump($v, false); 990 991 $ret[] = $indent . $k . ' : ' . self::dump($v, false, $indent); 989 992 } 990 $ret[] = ")"; 993 $indent = substr($indent,0, -4); 994 $ret[] = $indent . ")"; 991 995 break; 992 996 case 'object':