> +
> +   /** Ordered list of supported algorithms by recommendation. */
> +   public static List<String> supportedAlgs() {
> +      return SUPPORTED_ALGS;
> +   }
> +
> +   public static String macOrSignature(String jwsAlg) {
> +      return 
> ALG_TO_SIGNATURE_ALG_AND_KEY_FACTORY.get(indexOf(jwsAlg)).get(1);
> +   }
> +
> +   public static KeyFactory keyFactory(String jwsAlg) {
> +      String keyFactoryAlgorithm = 
> ALG_TO_SIGNATURE_ALG_AND_KEY_FACTORY.get(indexOf(jwsAlg)).get(2);
> +      try {
> +         return KeyFactory.getInstance(keyFactoryAlgorithm);
> +      } catch (NoSuchAlgorithmException e) {
> +         throw new AssertionError("Invalid contents in JWSAlgorithms! " + 
> e.getMessage());

[minor] Include the contents of `ALG_TO_SIGNATURE_ALG_AND_KEY_FACTORY` in the 
error message?

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs-google/pull/90/files#r20220352

Reply via email to