class JwtBundle implements BundleSource<JwtBundle> {

    public static JwtBundle parse(
            @NonNull final TrustDomain trustDomain,
            @NonNull final byte[] bundleBytes)
            throws JwtBundleException {
        try {
            val jwkSet = JWKSet.parse(new String(bundleBytes));
            return toJwtBundle(trustDomain, jwkSet);
        } catch (ParseException | JOSEException | KeyException e) {
            throw new JwtBundleException("Could not parse bundle from bytes", e);
        }
    }

    public  JwtBundle(@NonNull final TrustDomain trustDomain);
    public  JwtBundle(@NonNull final TrustDomain trustDomain, @NonNull final Map<String, PublicKey> jwtAuthorities);

}