Class SignaturePolicyValidationResult

java.lang.Object
eu.europa.esig.dss.validation.policy.SignaturePolicyValidationResult

public class SignaturePolicyValidationResult extends Object
Contains results of a SignaturePolicy validation
  • Constructor Summary

    Constructors
    Constructor
    Description
    Default constructor instantiating object with null values
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addError(String errorKey, String errorMessage)
    This method allows to add a new error message occurred during the validation
    Returns Digest that have been computed on the obtained signature policy document NOTE: can return NULL if a validator was not able to compute the digest
    protected Map<String,String>
    Returns a list of error messages occurred in the validation process
    Returns a user-friendly String with obtained error messages occurred during the validation process
    boolean
    Returns if the signature policy is ASN.1 processable
    boolean
    Returns if the DigestAlgorithm defined in the policy and used for the validation do match
    boolean
    Returns if the signature policy has been validated successfully
    boolean
    Returns if the signature policy has been obtained successfully
    void
    setAsn1Processable(boolean asn1Processable)
    Sets if the signature policy is ASN.1 processable
    void
    setDigest(Digest digest)
    Sets Digest that have been computed on the extracted signature policy document
    void
    setDigestAlgorithmsEqual(boolean digestAlgorithmsEqual)
    Sets if the digest algorithms match
    void
    setDigestValid(boolean digestValid)
    Sets if the signature policy is valid
    void
    setIdentified(boolean identified)
    Sets if the signature policy has been obtained successfully

    Methods inherited from class java.lang.Object

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

    • SignaturePolicyValidationResult

      public SignaturePolicyValidationResult()
      Default constructor instantiating object with null values
  • Method Details

    • isIdentified

      public boolean isIdentified()
      Returns if the signature policy has been obtained successfully
      Returns:
      TRUE if the signature policy has been identified, FALSE otherwise
    • setIdentified

      public void setIdentified(boolean identified)
      Sets if the signature policy has been obtained successfully
      Parameters:
      identified - if the signature policy has been identified
    • isDigestValid

      public boolean isDigestValid()
      Returns if the signature policy has been validated successfully
      Returns:
      TRUE if the signature policy is valid, FALSE otherwise
    • setDigestValid

      public void setDigestValid(boolean digestValid)
      Sets if the signature policy is valid
      Parameters:
      digestValid - if the signature policy is valid
    • isAsn1Processable

      public boolean isAsn1Processable()
      Returns if the signature policy is ASN.1 processable
      Returns:
      TRUE if the policy of ASN.1 encoded format, FALSE otherwise
    • setAsn1Processable

      public void setAsn1Processable(boolean asn1Processable)
      Sets if the signature policy is ASN.1 processable
      Parameters:
      asn1Processable - if the policy of ASN.1 encoded format
    • isDigestAlgorithmsEqual

      public boolean isDigestAlgorithmsEqual()
      Returns if the DigestAlgorithm defined in the policy and used for the validation do match
      Returns:
      TRUE if the digest algorithms match, FALSE otherwise
    • setDigestAlgorithmsEqual

      public void setDigestAlgorithmsEqual(boolean digestAlgorithmsEqual)
      Sets if the digest algorithms match
      Parameters:
      digestAlgorithmsEqual - if the digest algorithms match
    • getDigest

      public Digest getDigest()
      Returns Digest that have been computed on the obtained signature policy document NOTE: can return NULL if a validator was not able to compute the digest
      Returns:
      Digest that have been computed in a signature policy document
    • setDigest

      public void setDigest(Digest digest)
      Sets Digest that have been computed on the extracted signature policy document
      Parameters:
      digest - Digest
    • getErrors

      protected Map<String,String> getErrors()
      Returns a list of error messages occurred in the validation process
      Returns:
      a map of error keys and messages
    • addError

      public void addError(String errorKey, String errorMessage)
      This method allows to add a new error message occurred during the validation
      Parameters:
      errorKey - String defines nature of the error
      errorMessage - String the error message
    • getProcessingErrors

      public String getProcessingErrors()
      Returns a user-friendly String with obtained error messages occurred during the validation process
      Returns:
      String validation errors