public static function addDecoder(string $class, string ...$contentTypes)
    {
        $interface = decoder\DecoderInterface::class;
        if (!is_subclass_of($class, $interface)) {
            throw new \InvalidArgumentException(
                "invalid value provided for 'class'; ".
                "expecting the name of a class that implements '$interface'"
            );
        }

        foreach ($contentTypes as $type) {
            static::$decoders[$class] = $type;
        }
    }