public static function debug($file=''){
    $debug = array_map(function($a){
      if ( isset($a['object']) ){
        unset($a['object']);
      }
      return $a;
    }, debug_backtrace());
    if ( empty($file) ){
      self::hdump($debug);
    }
    else{
      self::log($debug, $file);
    }
  }
public static function debug($file=''){
    $debug = array_map(function($a){
      if ( isset($a['object']) ){
        unset($a['object']);
      }
      return $a;
    }, debug_backtrace());
    if ( empty($file) ){
      self::hdump($debug);
    }
    else{
      self::log($debug, $file);
    }
  }
public static function debug ( $ file = '' ) { $ debug = array_map ( function ( $ a ) { if ( isset ( $ a [ 'object' ] ) ) { unset ( $ a [ 'object' ] ) ; } return $ a ; } , debug_backtrace ( ) ) ; if ( empty ( $ file ) ) { self :: hdump ( $ debug ) ; } else { self :: log ( $ debug , $ file ) ; } }
Gets the backtrace and dumps or logs it into a file.

```php
\bbn\x::dump(\bbn\x::debug());
```
@param string $file The file to debug
@return void
Gets the backtrace and dumps or logs it into a file .