Class DirectJobResponse

java.lang.Object
no.digipost.signature.client.direct.DirectJobResponse

public class DirectJobResponse extends Object
  • Constructor Details

  • Method Details

    • getSignatureJobId

      public long getSignatureJobId()
    • getReference

      public String getReference()
      Returns:
      the signature job's custom reference as specified upon creation. May be null.
    • getSingleSigner

      public DirectSignerResponse getSingleSigner()
      Gets the single signer for this job. Convenience method for retrieving the signer for jobs with exactly one signer.
      Returns:
      the signer
      Throws:
      IllegalStateException - if there are multiple signers for this job
      See Also:
    • getSigners

      public List<DirectSignerResponse> getSigners()
      Gets all the signers for this job
      Returns:
      the signers
    • getSignerIdentifiedBy

      public DirectSignerResponse getSignerIdentifiedBy(String identifier)
      Get the signer with the given identifier for this job.
      Parameters:
      identifier - the string identifying the signer, either a personal identification number, or a custom identifier
      Returns:
      the signer with the given identifier
      Throws:
      NoSuchElementException - if the signer was not found.
    • findSignerIdentifiedBy

      public Optional<DirectSignerResponse> findSignerIdentifiedBy(String identifier)
      Try to find the signer with the given identifier for this job. If you expect the signer to exist, consider using getSignerIdentifiedBy(String) instead.
      Parameters:
      identifier - the string identifying the signer, either a personal identification number, or a custom identifier
      Returns:
      the found signer, or empty.
    • getStatusUrl

      public URI getStatusUrl()