private function preferred(ServerRequestInterface $request): RequestHandlerInterface
    {
        $negotiator = new Negotiator;
        $accept = $request->getHeaderLine('Accept', '*/*');
        $priorities = array_keys($this->handlers);

        $best = $negotiator->getBest($accept, $priorities);

        $mediatype = $best ? $best->getValue() : current($priorities);

        return $this->handlers[$mediatype];
    }