NodeTrigger.php 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. /* vim: set expandtab sw=4 ts=4 sts=4: */
  3. /**
  4. * Functionality for the navigation tree
  5. *
  6. * @package PhpMyAdmin-Navigation
  7. */
  8. namespace PhpMyAdmin\Navigation\Nodes;
  9. use PhpMyAdmin\Util;
  10. /**
  11. * Represents a trigger node in the navigation tree
  12. *
  13. * @package PhpMyAdmin-Navigation
  14. */
  15. class NodeTrigger extends Node
  16. {
  17. /**
  18. * Initialises the class
  19. *
  20. * @param string $name An identifier for the new node
  21. * @param int $type Type of node, may be one of CONTAINER or OBJECT
  22. * @param bool $is_group Whether this object has been created
  23. * while grouping nodes
  24. */
  25. public function __construct($name, $type = Node::OBJECT, $is_group = false)
  26. {
  27. parent::__construct($name, $type, $is_group);
  28. $this->icon = Util::getImage('b_triggers');
  29. $this->links = array(
  30. 'text' => 'db_triggers.php?server=' . $GLOBALS['server']
  31. . '&amp;db=%3$s&amp;item_name=%1$s&amp;edit_item=1',
  32. 'icon' => 'db_triggers.php?server=' . $GLOBALS['server']
  33. . '&amp;db=%3$s&amp;item_name=%1$s&amp;export_item=1',
  34. );
  35. $this->classes = 'trigger';
  36. }
  37. }