original_string: public function implementedEvents()
      {
          $methodMap = [
              'config/routes' => 'beforeRenderRoutes',
              'Controller/component' => 'beforeRenderComponent',
              'Controller/controller' => 'beforeRenderController',
              'Model/behavior' => 'beforeRenderBehavior',
              'Model/entity' => 'beforeRenderEntity',
              'Model/table' => 'beforeRenderTable',
              'Shell/shell' => 'beforeRenderShell',
              'View/cell' => 'beforeRenderCell',
              'View/helper' => 'beforeRenderHelper',
              'tests/test_case' => 'beforeRenderTestCase',
          ];
  
          $events = [];
          foreach ($methodMap as $template => $method) {
              if ($this->isType($template) && method_exists($this, $method)) {
                  $events[sprintf('Bake.%s', $method)] = $method;
              }
          }
  
          return $events;
      }
code: public function implementedEvents()
      {
          $methodMap = [
              'config/routes' => 'beforeRenderRoutes',
              'Controller/component' => 'beforeRenderComponent',
              'Controller/controller' => 'beforeRenderController',
              'Model/behavior' => 'beforeRenderBehavior',
              'Model/entity' => 'beforeRenderEntity',
              'Model/table' => 'beforeRenderTable',
              'Shell/shell' => 'beforeRenderShell',
              'View/cell' => 'beforeRenderCell',
              'View/helper' => 'beforeRenderHelper',
              'tests/test_case' => 'beforeRenderTestCase',
          ];
  
          $events = [];
          foreach ($methodMap as $template => $method) {
              if ($this->isType($template) && method_exists($this, $method)) {
                  $events[sprintf('Bake.%s', $method)] = $method;
              }
          }
  
          return $events;
      }
code_tokens: public function implementedEvents ( ) { $ methodMap = [ 'config/routes' => 'beforeRenderRoutes' , 'Controller/component' => 'beforeRenderComponent' , 'Controller/controller' => 'beforeRenderController' , 'Model/behavior' => 'beforeRenderBehavior' , 'Model/entity' => 'beforeRenderEntity' , 'Model/table' => 'beforeRenderTable' , 'Shell/shell' => 'beforeRenderShell' , 'View/cell' => 'beforeRenderCell' , 'View/helper' => 'beforeRenderHelper' , 'tests/test_case' => 'beforeRenderTestCase' , ] ; $ events = [ ] ; foreach ( $ methodMap as $ template => $ method ) { if ( $ this -> isType ( $ template ) && method_exists ( $ this , $ method ) ) { $ events [ sprintf ( 'Bake.%s' , $ method ) ] = $ method ; } } return $ events ; }
docstring: Get the callbacks this class is interested in.
  
  @return array
docstring_tokens: Get the callbacks this class is interested in .