1 layout_menu_item.class.inc LayoutMenuItem::checkAccess()

Check access to this menu item based on the current contexts.

See also

_layout_page_access()

File

core/modules/layout/includes/layout_menu_item.class.inc, line 319
Class for storing information about menu item entries.

Class

LayoutMenuItem
@file Class for storing information about menu item entries.

Code

function checkAccess() {
  $contexts = $this->getContexts();
  foreach ($this->conditions as $condition) {
    $condition->setContexts($contexts);
    if (!$condition->checkAccess()) {
      return FALSE;
    }
  }
  return TRUE;
}