Module jpms_dss_spi

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 Summary

    Constructors
    Constructor
    Description
    DSSMessageDigestCalculator(eu.europa.esig.dss.enumerations.DigestAlgorithm digestAlgorithm)
    Default constructor
  • Method Summary

    Modifier and Type
    Method
    Description
    eu.europa.esig.dss.model.DSSMessageDigest
    Returns the DSSMessageDigest accordingly to the current state.
    void
    update(byte byteToAdd)
    Updates the digest using the provided byte
    void
    update(byte[] bytes)
    Updates the digest using the provided array of bytes

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DSSMessageDigestCalculator

      public DSSMessageDigestCalculator(eu.europa.esig.dss.enumerations.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 eu.europa.esig.dss.model.DSSMessageDigest getMessageDigest()
      Returns the DSSMessageDigest accordingly to the current state. This method resets the state of message-digest.
      Returns:
      DSSMessageDigest