You are here

function xhprof_menu in XHProf 7

Same name and namespace in other branches
  1. 6 xhprof.module \xhprof_menu()

Implementation of hook_menu().

File

./xhprof.module, line 8

Code

function xhprof_menu() {
  $items = array();
  $items[XHPROF_PATH] = array(
    'title' => 'XHProf runs',
    'page callback' => 'xhprof_run_list',
    'access arguments' => array(
      'access xhprof data',
    ),
    'description' => 'View XHProf profiling data.',
  );
  $items[XHPROF_PATH . '/%'] = array(
    'title' => 'XHProf view',
    'page callback' => 'xhprof_display_page',
    'page arguments' => array(
      3,
    ),
    'access arguments' => array(
      'access xhprof data',
    ),
  );
  $items[XHPROF_PATH . '/diff/%/%'] = array(
    'title' => 'XHProf view',
    'page callback' => 'xhprof_display_diff_page',
    'page arguments' => array(
      4,
      5,
    ),
    'access arguments' => array(
      'access xhprof data',
    ),
  );
  $items[XHPROF_PATH . '/%/symbol/%'] = array(
    'title' => 'XHProf view',
    'page callback' => 'xhprof_display_page',
    'page arguments' => array(
      3,
      5,
    ),
    'access arguments' => array(
      'access xhprof data',
    ),
  );
  $items['admin/config/development/xhprof'] = array(
    'title' => 'XHProf settings',
    'description' => 'Configure XHProf profiler settings.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'xhprof_admin_settings',
    ),
    'file' => 'xhprof.admin.inc',
    'access arguments' => array(
      'administer site configuration',
    ),
  );
  return $items;
}