Class MD5Digest


  • public class MD5Digest
    extends java.lang.Object
    Provides MD5 via java.security based implementation.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private static int DIGEST_LENGTH  
      (package private) java.security.MessageDigest md  
    • Constructor Summary

      Constructors 
      Constructor Description
      MD5Digest()
      Standard constructor
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int doFinal​(byte[] out, int outOff)  
      void finish()  
      java.lang.String getAlgorithmName()  
      int getDigestSize()  
      void reset()
      Resets the digest for further use.
      void update​(byte in)  
      void update​(byte[] in, int inOff, int len)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • md

        java.security.MessageDigest md
    • Constructor Detail

      • MD5Digest

        public MD5Digest()
        Standard constructor

        Note: the previous implementation (non-java.security based) also included a copy constructor. This has been removed as it doesn't make sense with the java.security based implementation.

    • Method Detail

      • getAlgorithmName

        public java.lang.String getAlgorithmName()
      • getDigestSize

        public int getDigestSize()
      • doFinal

        public int doFinal​(byte[] out,
                           int outOff)
      • reset

        public void reset()
        Resets the digest for further use.
      • update

        public void update​(byte in)
      • update

        public void update​(byte[] in,
                           int inOff,
                           int len)
      • finish

        public void finish()