Overview

Namespaces

  • None
  • Xmf
    • Database
    • Module
      • Helper
    • Template
  • Xoops
    • Auth
    • Core
      • Cache
      • Database
        • Logging
        • Schema
      • Exception
      • Handler
        • Scheme
      • Kernel
        • Dtype
        • Handlers
        • Model
      • Lists
      • Locale
        • Punic
      • Service
        • Contract
      • Session
      • Text
        • Sanitizer
          • Extensions
      • Theme
        • Plugins
    • Form
    • Html
    • Locale
    • Module
      • Helper
      • Plugin

Classes

  • Debug
  • FilterInput
  • Highlighter
  • Language
  • Loader
  • Metagen
  • Request
  • Utilities
  • Yaml
  • Overview
  • Namespace
  • Class
  • Tree

Class Debug

Debugging tools for developers

Namespace: Xmf
Package: Xmf
Category: Xmf\Module\Debug
Copyright: 2011-2015 XOOPS Project (http://xoops.org)
License: GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
Author: trabis lusopoemas@gmail.com
Author: Richard Griffith richard@geekwright.com
Version: Release: 1.0
Since: 1.0
Link: http://xoops.org
Located at oops_lib/Xmf/Debug.php
Methods summary
public static
# dump( mixed $var, boolean $inline = false )

Dump a variable

Dump a variable

Parameters

$var
variable which will be dumped
$inline

force inline display if true, otherwise will attempt to use debug.log event

public static mixed|string
# backtrace( boolean $inline = false )

Display debug backtrace

Display debug backtrace

Parameters

$inline

force inline display if true, otherwise will attempt to use debug.log event

Returns

mixed|string
public static
# startTimer( string $name, string|null $label = null )

Start a timer

Start a timer

Parameters

$name
unique name for timer
$label
optional label for this timer
public static
# stopTimer( string $name )

Stop a timer

Stop a timer

Parameters

$name
unique name for timer
public static
# startQueuedTimer( string $name, string|null $label = null )

Start a queued timer. Queued timers are stored and only dumped by request. This makes them useful in recording timing when immediate output is not possible practical, such as early system startup activities. Timers can be queued at any point once the Xmf\Debug class can be loaded then dumped when system facilities are available.

Start a queued timer. Queued timers are stored and only dumped by request. This makes them useful in recording timing when immediate output is not possible practical, such as early system startup activities. Timers can be queued at any point once the Xmf\Debug class can be loaded then dumped when system facilities are available.

Parameters

$name
unique name for timer
$label
optional label for this timer
public static
# stopQueuedTimer( string $name )

Stop a queued timer

Stop a queued timer

Parameters

$name
unique name for timer
public static array
# dumpQueuedTimers( boolean $returnOnly = false )

dump and queued timer data and reset the queue

dump and queued timer data and reset the queue

Note: The DebugBar logger will add any unprocessed queue data to its timeline automatically, if you use queued timers and don't call this.

Parameters

$returnOnly
if true do not dump queue, only return it

Returns

array
of time data see \Xmf\Debug::$timerQueue
public static
# startTrace( type $tracefile = '', type $collect_params = '3', type $collect_return = 'On' )

start_trace - turn on xdebug trace

start_trace - turn on xdebug trace

Requires xdebug extension

Parameters

$tracefile
file name for trace file
$collect_params

argument for ini_set('xdebug.collect_params',?) Controls display of parameters in trace output

$collect_return

argument for ini_set('xdebug.collect_return',?) Controls display of function return value in trace

public static
# stopTrace( )

stop_trace - turn off xdebug trace

stop_trace - turn off xdebug trace

Requires xdebug extension

API documentation generated by ApiGen