src/Service/Router/Route.php
public function setSuccessLocationHeader(
        string $location,
        EntityFactoryConfig $config,
        int $status = 302
    ): RouteInterface {
        return $this->addFirst(new SuccessHeaderLocationMiddleware($location, $config, $status));
    }
public function setSuccessLocationHeader(
        string $location,
        EntityFactoryConfig $config,
        int $status = 302
    ): RouteInterface {
        return $this->addFirst(new SuccessHeaderLocationMiddleware($location, $config, $status));
    }
public function setSuccessLocationHeader ( string $ location , EntityFactoryConfig $ config , int $ status = 302 ) : RouteInterface { return $ this -> addFirst ( new SuccessHeaderLocationMiddleware ( $ location , $ config , $ status ) ) ; }
Add a Location header to the response

Can take a placeholder to replace a variable by an entity getter
e.g.
```php
'/resource/{id}'
```
will be replaced by
```php
'/resource/' . $entity->getId()
```

@param string $location
@param EntityFactoryConfig $config

@param int $status

@return RouteInterface
Add a Location header to the response