Class DSSMessageDigestCalculator

java.lang.Object
eu.europa.esig.dss.spi.DSSMessageDigestCalculator

public class DSSMessageDigestCalculator extends Object
This class is used to compute DSSMessageDigest based on the provided input
  • Constructor Details

    • DSSMessageDigestCalculator

      public DSSMessageDigestCalculator(DigestAlgorithm digestAlgorithm)
      Default constructor
      Parameters:
      digestAlgorithm - DigestAlgorithm to be used for message-digest computation
  • Method Details

    • update

      public void update(byte byteToAdd)
      Updates the digest using the provided byte
      Parameters:
      byteToAdd - byte to be added for digest computation
    • update

      public void update(byte[] bytes)
      Updates the digest using the provided array of bytes
      Parameters:
      bytes - array of bytes
    • getMessageDigest

      public DSSMessageDigest getMessageDigest()
      Returns the DSSMessageDigest accordingly to the current state. This method resets the state of message-digest.
      Returns:
      DSSMessageDigest