public static String getAlgorithm ( final URI digestUri ) { if ( digestUri == null ) { return DEFAULT_ALGORITHM ; } return DIGEST_ALGORITHM . fromScheme ( digestUri . getScheme ( ) + ":" + digestUri . getSchemeSpecificPart ( ) . split ( ":" , 2 ) [ 0 ] ) . algorithm ; }
Given a digest URI get the corresponding MessageDigest algorithm