original_string: public function getActionMap()
      {
          $plugins = $this->getLoadedPluginPaths();
  
          $actionMap = [];
          foreach ($plugins as $plugin => $path) {
              $controllers = $this->getControllersForPlugin($plugin, $path);
              foreach ($controllers as $controller) {
                  $actions = $this->introspectController($controller['path']);
                  if (empty($actions)) {
                      continue;
                  }
                  foreach ($actions as $action) {
                      $path = "{$plugin}.{$controller['name']}.{$action}";
                      if (in_array($path, $this->_guestActions)) {
                          continue;
                      }
                      $actionMap[$path] = [
                          'plugin' => $plugin,
                          'controller' => $controller['name'],
                          'action' => $action
                      ];
                  }
              }
          }
  
          $appControllers = $this->getControllersForApp();
          foreach ($appControllers as $controller) {
              $actions = $this->introspectController($controller['path']);
  
              if (empty($actions)) {
                  continue;
              }
              foreach ($actions as $action) {
                  if (strpos($controller['path'], ROOT . DS . 'src' . DS . 'Controller') === false) {
                      $path = "App.{$controller['name']}.{$action}";
                      if (in_array($path, $this->_guestActions)) {
                          continue;
                      }
                      $actionMap[$path] = [
                          'plugin' => 'App',
                          'controller' => $controller['name'],
                          'action' => $action
                      ];
                  } else {
                      $namespaceParts = explode(DS, substr($controller['path'], strlen(ROOT . DS . 'src' . DS . 'Controller') + 1));
                      array_pop($namespaceParts);
                      $namespace = join('/', $namespaceParts);
                      if (!empty($namespace)) {
                          $path = "App.{$namespace}/{$controller['name']}.{$action}";
                      } else {
                          $path = "App.{$controller['name']}.{$action}";
                      }
                      if (in_array($path, $this->_guestActions)) {
                          continue;
                      }
                      $actionMap[$path] = [
                          'plugin' => 'App',
                          'controller' => !empty($namespace) ? $namespace . '/' . $controller['name'] : $controller['name'],
                          'action' => $action
                      ];
                  }
              }
          }
  
          return $actionMap;
      }
code: public function getActionMap()
      {
          $plugins = $this->getLoadedPluginPaths();
  
          $actionMap = [];
          foreach ($plugins as $plugin => $path) {
              $controllers = $this->getControllersForPlugin($plugin, $path);
              foreach ($controllers as $controller) {
                  $actions = $this->introspectController($controller['path']);
                  if (empty($actions)) {
                      continue;
                  }
                  foreach ($actions as $action) {
                      $path = "{$plugin}.{$controller['name']}.{$action}";
                      if (in_array($path, $this->_guestActions)) {
                          continue;
                      }
                      $actionMap[$path] = [
                          'plugin' => $plugin,
                          'controller' => $controller['name'],
                          'action' => $action
                      ];
                  }
              }
          }
  
          $appControllers = $this->getControllersForApp();
          foreach ($appControllers as $controller) {
              $actions = $this->introspectController($controller['path']);
  
              if (empty($actions)) {
                  continue;
              }
              foreach ($actions as $action) {
                  if (strpos($controller['path'], ROOT . DS . 'src' . DS . 'Controller') === false) {
                      $path = "App.{$controller['name']}.{$action}";
                      if (in_array($path, $this->_guestActions)) {
                          continue;
                      }
                      $actionMap[$path] = [
                          'plugin' => 'App',
                          'controller' => $controller['name'],
                          'action' => $action
                      ];
                  } else {
                      $namespaceParts = explode(DS, substr($controller['path'], strlen(ROOT . DS . 'src' . DS . 'Controller') + 1));
                      array_pop($namespaceParts);
                      $namespace = join('/', $namespaceParts);
                      if (!empty($namespace)) {
                          $path = "App.{$namespace}/{$controller['name']}.{$action}";
                      } else {
                          $path = "App.{$controller['name']}.{$action}";
                      }
                      if (in_array($path, $this->_guestActions)) {
                          continue;
                      }
                      $actionMap[$path] = [
                          'plugin' => 'App',
                          'controller' => !empty($namespace) ? $namespace . '/' . $controller['name'] : $controller['name'],
                          'action' => $action
                      ];
                  }
              }
          }
  
          return $actionMap;
      }
code_tokens: public function getActionMap ( ) { $ plugins = $ this -> getLoadedPluginPaths ( ) ; $ actionMap = [ ] ; foreach ( $ plugins as $ plugin => $ path ) { $ controllers = $ this -> getControllersForPlugin ( $ plugin , $ path ) ; foreach ( $ controllers as $ controller ) { $ actions = $ this -> introspectController ( $ controller [ 'path' ] ) ; if ( empty ( $ actions ) ) { continue ; } foreach ( $ actions as $ action ) { $ path = "{$plugin}.{$controller['name']}.{$action}" ; if ( in_array ( $ path , $ this -> _guestActions ) ) { continue ; } $ actionMap [ $ path ] = [ 'plugin' => $ plugin , 'controller' => $ controller [ 'name' ] , 'action' => $ action ] ; } } } $ appControllers = $ this -> getControllersForApp ( ) ; foreach ( $ appControllers as $ controller ) { $ actions = $ this -> introspectController ( $ controller [ 'path' ] ) ; if ( empty ( $ actions ) ) { continue ; } foreach ( $ actions as $ action ) { if ( strpos ( $ controller [ 'path' ] , ROOT . DS . 'src' . DS . 'Controller' ) === false ) { $ path = "App.{$controller['name']}.{$action}" ; if ( in_array ( $ path , $ this -> _guestActions ) ) { continue ; } $ actionMap [ $ path ] = [ 'plugin' => 'App' , 'controller' => $ controller [ 'name' ] , 'action' => $ action ] ; } else { $ namespaceParts = explode ( DS , substr ( $ controller [ 'path' ] , strlen ( ROOT . DS . 'src' . DS . 'Controller' ) + 1 ) ) ; array_pop ( $ namespaceParts ) ; $ namespace = join ( '/' , $ namespaceParts ) ; if ( ! empty ( $ namespace ) ) { $ path = "App.{$namespace}/{$controller['name']}.{$action}" ; } else { $ path = "App.{$controller['name']}.{$action}" ; } if ( in_array ( $ path , $ this -> _guestActions ) ) { continue ; } $ actionMap [ $ path ] = [ 'plugin' => 'App' , 'controller' => ! empty ( $ namespace ) ? $ namespace . '/' . $ controller [ 'name' ] : $ controller [ 'name' ] , 'action' => $ action ] ; } } } return $ actionMap ; }
docstring: Get a mapped array of all guardable controller actions
  excluding the provided guest actions.
  
  @return array
docstring_tokens: Get a mapped array of all guardable controller actions excluding the provided guest actions .