code: public function map($route, $name, $handler, array $methods = array('GET'))
      {
          foreach ($methods as $method) {
              if (null === $name) {
                  $this->addRoute($method, $route, $handler);
              } else {
                  $this->addNamedRoute($name, $method, $route, $handler);
              }
          }
      }
docs: Map a handler to the given methods and route
  
  @param string          $route   The route to match against
  @param string          $name    The name of the route
  @param string|callable $handler The handler for the route
  @param array|string[]  $methods The HTTP methods for this handler